Skip to content

Commit a0e8c24

Browse files
committed
feat: add denyCommand handler for individual command deny listing
1 parent 20363b4 commit a0e8c24

File tree

2 files changed

+3
-4
lines changed

2 files changed

+3
-4
lines changed

src/core/webview/webviewMessageHandler.ts

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -842,9 +842,7 @@ export const webviewMessageHandler = async (
842842
.update("deniedCommands", validCommands, vscode.ConfigurationTarget.Global)
843843

844844
// Show confirmation to the user
845-
vscode.window.showInformationMessage(
846-
t("common:info.command_denied", { pattern: message.pattern }),
847-
)
845+
vscode.window.showInformationMessage(t("common:info.command_denied", { pattern: message.pattern }))
848846

849847
// Update the webview state
850848
await provider.postStateToWebview()

src/i18n/locales/en/common.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -103,7 +103,8 @@
103103
"image_saved": "Image saved to {{path}}",
104104
"mode_exported": "Mode '{{mode}}' exported successfully",
105105
"mode_imported": "Mode imported successfully",
106-
"command_whitelisted": "Command pattern '{{pattern}}' has been added to the allowed commands list"
106+
"command_whitelisted": "Command pattern '{{pattern}}' has been added to the allowed commands list",
107+
"command_denied": "Command pattern '{{pattern}}' has been added to the denied commands list"
107108
},
108109
"answers": {
109110
"yes": "Yes",

0 commit comments

Comments
 (0)