Move to FK pragma and prep other code points in light of that

This commit is contained in:
Jack Kingsman
2026-04-01 21:22:01 -07:00
parent 47c4f038fe
commit 4a2d7ed100
6 changed files with 238 additions and 34 deletions
+3
View File
@@ -572,6 +572,9 @@ class MessageRepository:
@staticmethod
async def delete_by_id(message_id: int) -> None:
"""Delete a message row by ID."""
await db.conn.execute(
"UPDATE raw_packets SET message_id = NULL WHERE message_id = ?", (message_id,)
)
await db.conn.execute("DELETE FROM messages WHERE id = ?", (message_id,))
await db.conn.commit()