Skip to content

Commit

Permalink
Merge pull request #249 from snyk/fix/auth-wizard-cancel-button
Browse files Browse the repository at this point in the history
fix: don't attempt to update language client config if there is no language client [IDE-844]
  • Loading branch information
andrewrobinsonhodges-snyk authored Dec 19, 2024
2 parents 6d52e62 + d281c12 commit 0b93830
Showing 1 changed file with 5 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,10 @@ public void resetPreferences() {
Preferences.getInstance().setIsInsecure(initialUnknownCerts);
Preferences.getInstance().store(Preferences.AUTH_TOKEN_KEY, initialAuthToken);

SnykExtendedLanguageClient.getInstance().updateConfiguration();
SnykExtendedLanguageClient client = SnykExtendedLanguageClient.getInstance();
// The language client may be null when the extension first loads, so only update configuration if we are able.
if (client != null) {
client.updateConfiguration();
};
}
}

0 comments on commit 0b93830

Please sign in to comment.