fix(cmd): nil-guard CLI when emitting system-prompt notice in quiet mode

SetupCLIForNonInteractive returns nil when --quiet is active, matching
the pre-existing nil checks elsewhere in the same block (e.g. the
buffered debug-message branch). Without this guard the new
'System Prompt loaded' notice panicked on quiet, non-interactive runs.

Discovered via tmux smoke test of the #25 fix.
This commit is contained in:
Ed Zynda
2026-05-08 10:44:01 +03:00
parent a95714a22d
commit da7e05eb87
+1 -1
View File
@@ -811,7 +811,7 @@ func runNormalMode(ctx context.Context) error {
}
DisplayDebugConfig(cli, kitInstance, mcpConfig, parsedProvider)
if systemPromptLoadedMsg != "" {
if systemPromptLoadedMsg != "" && cli != nil {
cli.DisplayInfo(systemPromptLoadedMsg)
}
}