From 2ac4c319a3420fdd2c05b42347ee2a0b53472517 Mon Sep 17 00:00:00 2001 From: Mauro Balades Date: Fri, 12 Jul 2024 18:43:10 +0200 Subject: [PATCH] refactor: Modify createDownloadsTable function in db.ts to remove unnecessary platform check constraint --- src/lib/db.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/lib/db.ts b/src/lib/db.ts index 897e916..284cb60 100644 --- a/src/lib/db.ts +++ b/src/lib/db.ts @@ -6,7 +6,7 @@ import { releases } from './releases'; async function createDownloadsTable() { await sql` CREATE TABLE IF NOT EXISTS downloads ( - platform TEXT NOT NULL PRIMARY KEY CONSTRAINT platform_check CHECK (platform IN ('WindowsZip', 'Linux')), + platform TEXT NOT NULL PRIMARY KEY, count INT NOT NULL DEFAULT 0 ); `;