1
0
mirror of https://github.com/Unleash/unleash.git synced 2025-02-19 00:15:43 +01:00

chore: add migration that backfills scim user email hashes (#9295)

This commit is contained in:
David Leek 2025-02-12 09:05:36 +01:00 committed by GitHub
parent 17e93509e9
commit 5921f0ea09
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -0,0 +1,14 @@
exports.up = (db, cb) => {
db.runSql(`
UPDATE users
SET email_hash = md5(email::text)
WHERE scim_id IS NOT NULL;
`, cb);
};
exports.down = (db, cb) => {
cb();
};