修复:软删除账号可复用用户名

This commit is contained in:
yml2213
2026-08-13 14:40:22 +08:00
parent 91c055c130
commit 33a30fcd99
3 changed files with 29 additions and 1 deletions
@@ -0,0 +1,3 @@
-- Soft-deleted accounts must not permanently reserve their login usernames.
DROP INDEX IF EXISTS idx_users_username;
CREATE UNIQUE INDEX idx_users_username ON users (username) WHERE deleted_at IS NULL;