Skip to content

Commit

Permalink
fixup! Delete personal access tokens without provider name annotation
Browse files Browse the repository at this point in the history
  • Loading branch information
vinokurig committed Jun 7, 2024
1 parent 9c630f8 commit ae43c64
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -220,7 +220,7 @@ public Optional<Pair<Boolean, String>> isValid(PersonalAccessTokenParams params)
// The url from the token has the same url as the api client, no need to create a new one.
apiClient = githubApiClient;
} else {
if (OAUTH_PROVIDER_NAME.equals(params.getScmTokenName())) {
if (OAUTH_PROVIDER_NAME.equals(params.getScmProviderName())) {
apiClient = new GithubApiClient(params.getScmProviderUrl());
} else {
LOG.debug("not a valid url {} for current fetcher ", params.getScmProviderUrl());
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -196,7 +196,7 @@ public Optional<Boolean> isValid(PersonalAccessToken personalAccessToken) {
public Optional<Pair<Boolean, String>> isValid(PersonalAccessTokenParams params) {
GitlabApiClient gitlabApiClient = getApiClient(params.getScmProviderUrl());
if (gitlabApiClient == null || !gitlabApiClient.isConnected(params.getScmProviderUrl())) {
if (OAUTH_PROVIDER_NAME.equals(params.getScmTokenName())) {
if (OAUTH_PROVIDER_NAME.equals(params.getScmProviderName())) {
gitlabApiClient = new GitlabApiClient(params.getScmProviderUrl());
} else {
LOG.debug("not a valid url {} for current fetcher ", params.getScmProviderUrl());
Expand Down

0 comments on commit ae43c64

Please sign in to comment.