fix(tui): address follow-up review nits

This commit is contained in:
Brooklyn Nicholson 2026-04-26 05:06:57 -05:00
parent a0aebad673
commit 2e6c3c7d23
6 changed files with 44 additions and 35 deletions

View file

@ -21,7 +21,7 @@ const GLOBAL_MODEL_FLAG_RE = /(?:^|\s)--global(?:\s|$)/
const persistedModelArg = (arg: string) => {
const trimmed = arg.trim()
return GLOBAL_MODEL_FLAG_RE.test(trimmed) ? trimmed : `${trimmed} --global`
return !trimmed || GLOBAL_MODEL_FLAG_RE.test(trimmed) ? trimmed : `${trimmed} --global`
}
export const sessionCommands: SlashCommand[] = [
@ -73,7 +73,7 @@ export const sessionCommands: SlashCommand[] = [
return
}
if (!arg) {
if (!arg.trim()) {
return patchOverlayState({ modelPicker: true })
}