Skip to content

Commit 0adeda0

Browse files
committed
refactor(db): Use JSON format and add missing FK to colorscheme data
1 parent 864d6b9 commit 0adeda0

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

db/migrations/20251005195216_colorschemes.sql

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,9 +7,9 @@ CREATE TABLE colorschemes (
77

88
CREATE TABLE colorscheme_color_data (
99
colorscheme_name TEXT NOT NULL,
10-
repository_id INTEGER NOT NULL,
10+
repository_id INTEGER NOT NULL REFERENCES repositories(id) ON DELETE CASCADE,
1111
background TEXT NOT NULL CHECK (background IN ('light', 'dark')),
12-
color_data TEXT NOT NULL,
12+
color_data JSON NOT NULL,
1313

1414
PRIMARY KEY (colorscheme_name, repository_id, background)
1515
)

0 commit comments

Comments
 (0)