Files
spsays-bff/migrations/0039_user_ban.up.sql
T
2026-06-16 14:47:45 +05:30

7 lines
363 B
SQL

-- Account suspension (ban) support for the admin panel. Additive: the column
-- is nullable and defaults to NULL (not banned), so existing rows and queries
-- are unaffected. Enforcement: RequireAuth rejects a user whose banned_at is
-- set, and LogIn refuses to issue a new session for one.
ALTER TABLE users
ADD COLUMN IF NOT EXISTS banned_at TIMESTAMPTZ;