fix: fall back to the user's system prompt when the chat's own is cleared (#30333)

This commit is contained in:
G30
2026-09-22 11:37:59 -04:00
committed by GitHub
parent 845b791609
commit f2702e1f0f
+1 -1
View File
@@ -3489,7 +3489,7 @@
// Only temp chats need conversation messages (persisted chats load from DB).
let messages: any[] = [
params?.system || $settings.system
? { role: 'system', content: `${params?.system ?? $settings?.system ?? ''}` }
? { role: 'system', content: `${params?.system || $settings?.system || ''}` }
: undefined
].filter(Boolean);