mirror of
https://github.com/lensapp/lens.git
synced 2025-05-20 05:10:56 +00:00
Correctly migrate duplicate clusters in workspaces (#3211)
- Keep track of the set of all workspaces that each duplicated entry was a part of Signed-off-by: Sebastian Malton <sebastian@malton.name>
This commit is contained in:
1 parent
b00afee15c
commit
05311c4b1b
4 files changed
+38
-11
No files matched your search
@@ -120,6 +120,10 @@ export class Cluster implements ClusterModel, ClusterState {
|
||||
* @deprecated
|
||||
*/
|
||||
@observable workspace: string;
|
||||
/**
|
||||
* @deprecated
|
||||
*/
|
||||
@observable workspaces: string[];
|
||||
/**
|
||||
* Kubernetes API server URL
|
||||
*
|
||||
@@ -294,6 +298,10 @@ export class Cluster implements ClusterModel, ClusterState {
|
||||
this.workspace = model.workspace;
|
||||
}
|
||||
|
||||
if (model.workspaces) {
|
||||
this.workspaces = model.workspaces;
|
||||
}
|
||||
|
||||
if (model.contextName) {
|
||||
this.contextName = model.contextName;
|
||||
}
|
||||
@@ -589,6 +597,7 @@ export class Cluster implements ClusterModel, ClusterState {
|
||||
contextName: this.contextName,
|
||||
kubeConfigPath: this.kubeConfigPath,
|
||||
workspace: this.workspace,
|
||||
workspaces: this.workspaces,
|
||||
preferences: this.preferences,
|
||||
metadata: this.metadata,
|
||||
accessibleNamespaces: this.accessibleNamespaces,
|
||||
|
||||
Reference in new issue
Block a user