2023-12-18 23:39:16 +01:00
|
|
|
-- 2023-10-28: Add email/password login
|
|
|
|
|
|
|
|
-- +migrate Up
|
|
|
|
|
|
|
|
alter table users add column password bytea null;
|
|
|
|
alter table users add column salt bytea null;
|
|
|
|
|
|
|
|
create table user_emails (
|
|
|
|
id bigint primary key,
|
|
|
|
user_id bigint not null references users (snowflake_id) on delete cascade,
|
2024-02-13 16:57:03 +01:00
|
|
|
email_address text not null unique
|
2023-12-18 23:39:16 +01:00
|
|
|
);
|
|
|
|
|
|
|
|
-- +migrate Down
|
|
|
|
|
|
|
|
alter table users drop column password;
|
|
|
|
alter table users drop column salt;
|
|
|
|
|
|
|
|
drop table user_emails;
|