diff --git a/node-client/src/config.ts b/node-client/src/config.ts index 361ea5675c..0259b01825 100644 --- a/node-client/src/config.ts +++ b/node-client/src/config.ts @@ -228,7 +228,7 @@ export class KubeConfig { // Format in file is {}, so slice it out and add '$' pathKey = '$' + pathKey.slice(1, -1); - config['access-token'] = jsonpath.query(resultObj, path); + config['access-token'] = jsonpath.query(resultObj, pathKey); token = 'Bearer ' + config['access-token']; } else { throw new Error('Token is expired!');