fix(web): scope Suspense to page body; guard formatConfig against null config

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This commit is contained in:
2026-07-04 16:12:21 +07:00
parent 8c35aed8f2
commit 7256adf637
3 changed files with 22 additions and 16 deletions
+1 -1
View File
@@ -74,7 +74,7 @@ const EMPTY_FORM: ChannelForm = { type: "telegram", chatId: "", botToken: "", ur
// (Object.entries по всему config печатал бы любое поле, включая случайно
// сохранённый секрет).
function formatConfig(type: string, config: object): string {
const c = config as Record<string, unknown>
const c = (config ?? {}) as Record<string, unknown>
if (type === "telegram") return c.chat_id ? `chat_id: ${String(c.chat_id)}` : ""
if (type === "webhook") return c.url ? `url: ${String(c.url)}` : ""
return ""