Attempt to fix Codespaces bug by declaring a default (#261484)

Fixes https://github.com/microsoft/vscode/issues/261238
This commit is contained in:
Tyler James Leonhardt
2025-08-13 09:44:28 -07:00
committed by GitHub
parent 137f939a31
commit d3c3cf8f50

View File

@@ -81,12 +81,11 @@ export function activate(context: vscode.ExtensionContext) {
}));
// Listener to prompt for reload when the fetch implementation setting changes
let beforeFetchSetting = vscode.workspace.getConfiguration('github-authentication').get<boolean>('useElectronFetch');
const beforeFetchSetting = vscode.workspace.getConfiguration().get<boolean>('github-authentication.useElectronFetch', true);
context.subscriptions.push(vscode.workspace.onDidChangeConfiguration(async e => {
if (e.affectsConfiguration('github-authentication.useElectronFetch')) {
const afterFetchSetting = vscode.workspace.getConfiguration('github-authentication').get<boolean>('useElectronFetch');
const afterFetchSetting = vscode.workspace.getConfiguration().get<boolean>('github-authentication.useElectronFetch', true);
if (beforeFetchSetting !== afterFetchSetting) {
beforeFetchSetting = afterFetchSetting;
const selection = await vscode.window.showInformationMessage(
vscode.l10n.t('GitHub Authentication - Reload required'),
{