diff --git a/.github/local-actions/changelog/main.js b/.github/local-actions/changelog/main.js index 479c9cd2f..f246f2522 100644 --- a/.github/local-actions/changelog/main.js +++ b/.github/local-actions/changelog/main.js @@ -68650,7 +68650,7 @@ Alternatively, a new token can be created at: ${GITHUB_TOKEN_GENERATE_URL} return AuthenticatedGitClient._authenticatedInstance; } static configure(token, userType = "user") { - if (AuthenticatedGitClient._authenticatedInstance) { + if (AuthenticatedGitClient._token) { throw Error("Unable to configure `AuthenticatedGitClient` as it has been configured already."); } AuthenticatedGitClient._token = token; diff --git a/github-actions/slash-commands/main.js b/github-actions/slash-commands/main.js index 66b5ac6dc..7a42d959b 100644 --- a/github-actions/slash-commands/main.js +++ b/github-actions/slash-commands/main.js @@ -70023,7 +70023,7 @@ Alternatively, a new token can be created at: ${GITHUB_TOKEN_GENERATE_URL} return AuthenticatedGitClient._authenticatedInstance; } static configure(token, userType = "user") { - if (AuthenticatedGitClient._authenticatedInstance) { + if (AuthenticatedGitClient._token) { throw Error("Unable to configure `AuthenticatedGitClient` as it has been configured already."); } AuthenticatedGitClient._token = token; diff --git a/ng-dev/utils/git/authenticated-git-client.ts b/ng-dev/utils/git/authenticated-git-client.ts index f63a128b6..7fdaae764 100644 --- a/ng-dev/utils/git/authenticated-git-client.ts +++ b/ng-dev/utils/git/authenticated-git-client.ts @@ -188,7 +188,7 @@ export class AuthenticatedGitClient extends GitClient { /** Configures an authenticated git client. */ static configure(token: string, userType: UserType = 'user'): void { - if (AuthenticatedGitClient._authenticatedInstance) { + if (AuthenticatedGitClient._token) { throw Error( 'Unable to configure `AuthenticatedGitClient` as it has been configured already.', );