From ccebefd6d057a754408dde1680e99493bf0b8aa3 Mon Sep 17 00:00:00 2001 From: Lauri Nevala Date: Mon, 22 Mar 2021 13:12:34 +0200 Subject: [PATCH] Return undefined if unlinked Signed-off-by: Lauri Nevala --- src/main/kubeconfig-manager.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/main/kubeconfig-manager.ts b/src/main/kubeconfig-manager.ts index b0234ab250..334c6d577a 100644 --- a/src/main/kubeconfig-manager.ts +++ b/src/main/kubeconfig-manager.ts @@ -32,7 +32,7 @@ export class KubeconfigManager { getPath() { // create proxy kubeconfig if it is removed - if (!this.tempFile || !fs.pathExistsSync(this.tempFile)) { + if (this.tempFile && !fs.pathExistsSync(this.tempFile)) { this.tempFile = this.createProxyKubeconfig(); }