Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions src/config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ function fileExists(filepath: string): boolean {
export interface ApiType {}

export class KubeConfig implements SecurityAuthentication {
private static authenticators: Authenticator[] = [
private authenticators: Authenticator[] = [
new AzureAuth(),
new GoogleCloudPlatformAuth(),
new ExecAuth(),
Expand Down Expand Up @@ -596,7 +596,7 @@ export class KubeConfig implements SecurityAuthentication {
if (!user) {
return;
}
let authenticator = KubeConfig.authenticators.find((elt: Authenticator) => {
let authenticator = this.authenticators.find((elt: Authenticator) => {
return elt.isAuthProvider(user);
});

Expand Down
2 changes: 1 addition & 1 deletion src/config_test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -1345,7 +1345,7 @@ describe('KubeConfig', () => {
// TODO: inject the exec command here?
const opts = {} as RequestOptions;
await config.applyToHTTPSOptions(opts);
const execAuthenticator = (KubeConfig as any).authenticators.find(
const execAuthenticator = (config as any).authenticators.find(
(authenticator) => authenticator instanceof ExecAuth,
);
deepStrictEqual(execAuthenticator.tokenCache.exec, JSON.parse(responseStr));
Expand Down