From 7681e421edb3933c8727cb0936bc8310d79df6e2 Mon Sep 17 00:00:00 2001
From: Pinapelz <yukais@pinapelz.com>
Date: Fri, 28 Nov 2025 22:46:28 -0500
Subject: fix: change news image table to handle multiple images for each post

---
 schema.sql | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

(limited to 'schema.sql')

diff --git a/schema.sql b/schema.sql
index 88e1120..dc32e3e 100644
--- a/schema.sql
+++ b/schema.sql
@@ -13,7 +13,8 @@ CREATE TABLE IF NOT EXISTS news (
 );
 
 CREATE TABLE IF NOT EXISTS news_images (
-    news_id VARCHAR(255) NOT NULL PRIMARY KEY,
+    id INTEGER PRIMARY KEY AUTOINCREMENT,
+    news_id VARCHAR(255) NOT NULL,
     image_url TEXT NOT NULL,
     link_url TEXT,
     FOREIGN KEY (news_id) REFERENCES news(news_id) ON DELETE CASCADE
-- 
cgit v1.2.3

