mirror of
https://github.com/lensapp/lens.git
synced 2025-05-20 05:10:56 +00:00
Use resolved pathname
Signed-off-by: Sebastian Malton <sebastian@malton.name>
This commit is contained in:
1 parent
b5ed6eb81e
commit
6e104c5652
1 file changed
+2
-2
@@ -92,7 +92,7 @@ function _parseKubeApi(path: string): IKubeApiParsed {
|
||||
} else {
|
||||
switch (left.length) {
|
||||
case 0:
|
||||
throw new Error(`invalid apiPath: ${path}`);
|
||||
throw new Error(`invalid apiPath: ${apiPath}`);
|
||||
case 4:
|
||||
[apiGroup, apiVersion, resource, name] = left;
|
||||
break;
|
||||
@@ -136,7 +136,7 @@ function _parseKubeApi(path: string): IKubeApiParsed {
|
||||
const apiBase = [apiPrefix, apiGroup, apiVersion, resource].filter(v => v).join("/");
|
||||
|
||||
if (!apiBase) {
|
||||
throw new Error(`invalid apiPath: ${path}`);
|
||||
throw new Error(`invalid apiPath: ${apiPath}`);
|
||||
}
|
||||
|
||||
return {
|
||||
|
||||
Reference in new issue
Block a user