Add avatar field constraint to not be NULL

This commit is contained in:
Johannes Zellner
2021-07-07 18:32:05 +02:00
parent de9d30117f
commit ba86802fc0
2 changed files with 7 additions and 3 deletions
+1 -1
View File
@@ -31,7 +31,7 @@ CREATE TABLE IF NOT EXISTS users(
resetToken VARCHAR(128) DEFAULT "",
resetTokenCreationTime TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP,
active BOOLEAN DEFAULT 1,
avatar MEDIUMBLOB,
avatar MEDIUMBLOB NOT NULL,
locationJson TEXT, // { locations: [{ ip, userAgent, city, country, ts }] }
INDEX creationTime_index (creationTime),