fix: split initDb into two queries (pg no multi-command prepared stmts)
All checks were successful
Deploy to dev.bl.pixeldev.eu / deploy (push) Successful in 2s

This commit is contained in:
OpenClaw Agent 2026-03-13 15:13:32 +00:00
parent 1ea5ac60cc
commit 1d082d9016

View File

@ -31,10 +31,12 @@ async function initDb() {
id INT PRIMARY KEY DEFAULT 1,
content TEXT NOT NULL DEFAULT '',
updated_at TIMESTAMPTZ NOT NULL DEFAULT NOW()
)
`);
await pool.query(
`INSERT INTO card_text (id, content) VALUES (1, $1) ON CONFLICT (id) DO NOTHING`,
[DEFAULT_TEXT]
);
INSERT INTO card_text (id, content) VALUES (1, $1)
ON CONFLICT (id) DO NOTHING;
`, [DEFAULT_TEXT]);
}
// ── CORS ──────────────────────────────────────────────────────────────────