From e3043f0f74c4f9ab1da7dc3ceb0b37b2fc12f1a3 Mon Sep 17 00:00:00 2001 From: Lauri Nevala Date: Thu, 10 Sep 2020 10:19:44 +0300 Subject: [PATCH] Fix cluster's apiUrl Signed-off-by: Lauri Nevala --- src/main/cluster.ts | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/main/cluster.ts b/src/main/cluster.ts index 8f17216c18..702384608b 100644 --- a/src/main/cluster.ts +++ b/src/main/cluster.ts @@ -82,8 +82,7 @@ export class Cluster implements ClusterModel { @action updateModel(model: ClusterModel) { Object.assign(this, model); - this.apiUrl = this.getKubeconfig().getCurrentCluster()?.server; - this.contextName = this.contextName || this.preferences.clusterName; + this.apiUrl = this.getKubeconfig().getCluster(this.getKubeconfig().getContextObject(this.contextName).cluster).server } @action