From c4632104a8f9c84c71dba8019fdbeec8c1a3e30b Mon Sep 17 00:00:00 2001 From: Imbus <> Date: Wed, 13 Mar 2024 11:46:17 +0100 Subject: [PATCH] Commenting out trigger related to salts --- backend/internal/database/migrations/0070_salts.sql | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/backend/internal/database/migrations/0070_salts.sql b/backend/internal/database/migrations/0070_salts.sql index 9fb0588..b84dfac 100644 --- a/backend/internal/database/migrations/0070_salts.sql +++ b/backend/internal/database/migrations/0070_salts.sql @@ -6,10 +6,11 @@ CREATE TABLE salts ( salt TEXT NOT NULL ); +-- Commented out for now, no time for good practices, which is atrocious -- Create a trigger to automatically generate a salt when inserting a new user record -CREATE TRIGGER generate_salt_trigger -AFTER INSERT ON users -BEGIN - INSERT INTO salts (salt) VALUES (randomblob(16)); - UPDATE users SET salt_id = (SELECT last_insert_rowid()) WHERE id = new.id; -END; +-- CREATE TRIGGER generate_salt_trigger +-- AFTER INSERT ON users +-- BEGIN +-- INSERT INTO salts (salt) VALUES (randomblob(16)); +-- UPDATE users SET salt_id = (SELECT last_insert_rowid()) WHERE id = new.id; +-- END;