mirror of
https://github.com/lensapp/lens.git
synced 2025-05-20 05:10:56 +00:00
Pass uniqueId to instance key to create new model every
time release details opened Signed-off-by: Alex Andreev <alex.andreev.email@gmail.com>
This commit is contained in:
parent
eddb5bdb56
commit
416ec1fdf8
@ -31,6 +31,7 @@ import assert from "assert";
|
|||||||
import activeThemeInjectable from "../../../../themes/active.injectable";
|
import activeThemeInjectable from "../../../../themes/active.injectable";
|
||||||
import type { ToHelmRelease } from "../../to-helm-release.injectable";
|
import type { ToHelmRelease } from "../../to-helm-release.injectable";
|
||||||
import toHelmReleaseInjectable from "../../to-helm-release.injectable";
|
import toHelmReleaseInjectable from "../../to-helm-release.injectable";
|
||||||
|
import uniqueId from "lodash/uniqueId";
|
||||||
|
|
||||||
const releaseDetailsModelInjectable = getInjectable({
|
const releaseDetailsModelInjectable = getInjectable({
|
||||||
id: "release-details-model",
|
id: "release-details-model",
|
||||||
@ -56,7 +57,7 @@ const releaseDetailsModelInjectable = getInjectable({
|
|||||||
},
|
},
|
||||||
|
|
||||||
lifecycle: lifecycleEnum.keyedSingleton({
|
lifecycle: lifecycleEnum.keyedSingleton({
|
||||||
getInstanceKey: (di, release: TargetHelmRelease) => `${release.namespace}/${release.name}`,
|
getInstanceKey: (di, release: TargetHelmRelease) => `${release.namespace}/${release.name}-${uniqueId()}`,
|
||||||
}),
|
}),
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user