make initial migrations work (no db file exists).

This commit is contained in:
2021-03-21 13:02:55 +01:00
parent e8ff696006
commit a4d5982e3c
2 changed files with 22 additions and 15 deletions
@@ -8,11 +8,10 @@ CREATE TABLE IF NOT EXISTS users (
email VARCHAR NOT NULL,
password VARCHAR NOT NULL,
role INTEGER DEFAULT 1 NOT NULL,
UNIQUE(username, email)
UNIQUE(username),
UNIQUE(email)
);
CREATE UNIQUE INDEX ux_username ON users(username);
CREATE TABLE IF NOT EXISTS links (
id INTEGER PRIMARY KEY NOT NULL,
title VARCHAR NOT NULL,