fix: remove admin instance username if setting disabled (#3398)

This commit is contained in:
HugoCasa
2024-03-12 14:25:01 +01:00
committed by GitHub
parent 094c309ca1
commit cedde04571
2 changed files with 4 additions and 0 deletions
@@ -0,0 +1 @@
-- Add down migration script here
@@ -0,0 +1,3 @@
-- Add up migration script here
UPDATE password SET username = NULL WHERE email = 'admin@windmill.dev'
AND (SELECT value FROM global_settings WHERE name = 'automate_username_creation') IS DISTINCT FROM 'true';