fix: "allow always" for commands with paths (#23558)

This commit is contained in:
Tommaso Sciortino
2026-03-23 17:25:31 +00:00
committed by GitHub
parent eb979d9681
commit edcf7de2c0
2 changed files with 5 additions and 7 deletions

View File

@@ -264,11 +264,7 @@ function normalizeCommandName(raw: string): string {
return raw.slice(1, -1);
}
}
const trimmed = raw.trim();
if (!trimmed) {
return trimmed;
}
return trimmed.split(/[\\/]/).pop() ?? trimmed;
return raw.trim();
}
function extractNameFromNode(node: Node): string | null {