mirror of
https://github.com/QwenLM/qwen-code.git
synced 2026-04-28 03:30:40 +00:00
fix: persist ProceedAlways permission outcome in compact mode (#3069)
Compact mode confirmation dialog uses ProceedAlways for "Allow always" option, but persistPermissionOutcome() only handled ProceedAlwaysProject and ProceedAlwaysUser, causing the permission to never be saved. Now ProceedAlways is treated as project scope (same as ProceedAlwaysProject).
This commit is contained in:
parent
cf81ac47ff
commit
d8e06f5c91
1 changed files with 4 additions and 3 deletions
|
|
@ -174,6 +174,7 @@ export async function persistPermissionOutcome(
|
|||
payload?: ToolConfirmationPayload,
|
||||
): Promise<void> {
|
||||
if (
|
||||
outcome !== ToolConfirmationOutcome.ProceedAlways &&
|
||||
outcome !== ToolConfirmationOutcome.ProceedAlwaysProject &&
|
||||
outcome !== ToolConfirmationOutcome.ProceedAlwaysUser
|
||||
) {
|
||||
|
|
@ -181,9 +182,9 @@ export async function persistPermissionOutcome(
|
|||
}
|
||||
|
||||
const scope =
|
||||
outcome === ToolConfirmationOutcome.ProceedAlwaysProject
|
||||
? 'project'
|
||||
: 'user';
|
||||
outcome === ToolConfirmationOutcome.ProceedAlwaysUser
|
||||
? 'user'
|
||||
: 'project';
|
||||
|
||||
// Read permissionRules from the stored confirmation details first,
|
||||
// falling back to payload for backward compatibility.
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue