File tree Expand file tree Collapse file tree 1 file changed +6
-6
lines changed
server/aws-lsp-codewhisperer/src/language-server/agenticChat/tools/mcp Expand file tree Collapse file tree 1 file changed +6
-6
lines changed Original file line number Diff line number Diff line change @@ -1145,14 +1145,17 @@ export class McpEventHandler {
11451145
11461146 try {
11471147 // Skip server config check for Built-in server
1148+ const serverConfig = McpManager . instance . getAllServerConfigs ( ) . get ( serverName )
11481149 if ( serverName !== 'Built-in' ) {
1149- const serverConfig = McpManager . instance . getAllServerConfigs ( ) . get ( serverName )
11501150 if ( ! serverConfig ) {
11511151 throw new Error ( `Server '${ serverName } ' not found` )
11521152 }
11531153 }
11541154
1155- const mcpServerPermission = await this . #processPermissionUpdates( updatedPermissionConfig )
1155+ const mcpServerPermission = await this . #processPermissionUpdates(
1156+ updatedPermissionConfig ,
1157+ serverConfig ?. __configPath__
1158+ )
11561159
11571160 // Store the permission config instead of applying it immediately
11581161 this . #pendingPermissionConfig = {
@@ -1347,10 +1350,7 @@ export class McpEventHandler {
13471350 /**
13481351 * Processes permission updates from the UI
13491352 */
1350- async #processPermissionUpdates( updatedPermissionConfig : any ) {
1351- // Get the appropriate agent path
1352- const agentPath = await this . #getAgentPath( )
1353-
1353+ async #processPermissionUpdates( updatedPermissionConfig : any , agentPath : string | undefined ) {
13541354 const perm : MCPServerPermission = {
13551355 enabled : true ,
13561356 toolPerms : { } ,
You can’t perform that action at this time.
0 commit comments