Refactor IdeContextStore (#8278)

This commit is contained in:
Tommaso Sciortino
2025-09-11 11:22:20 -07:00
committed by GitHub
parent 538e6cd19a
commit d892cde0b0
10 changed files with 92 additions and 114 deletions
+2 -2
View File
@@ -49,7 +49,7 @@ import {
import { shouldAttemptBrowserLaunch } from '../utils/browser.js';
import type { MCPOAuthConfig } from '../mcp/oauth-provider.js';
import { IdeClient } from '../ide/ide-client.js';
import { ideContext } from '../ide/ideContext.js';
import { ideContextStore } from '../ide/ideContext.js';
import type { FileSystemService } from '../services/fileSystemService.js';
import { StandardFileSystemService } from '../services/fileSystemService.js';
import {
@@ -839,7 +839,7 @@ export class Config {
// restarts in the more common path. If the user chooses to mark the folder
// as untrusted, the CLI will restart and we will have the trust value
// reloaded.
const context = ideContext.getIdeContext();
const context = ideContextStore.get();
if (context?.workspaceState?.isTrusted !== undefined) {
return context.workspaceState.isTrusted;
}