ai-chatbot/lib/db/migrations/0062_add_single_active_session.sql
Your Name 366e0e3e5c
Some checks failed
Lint / build (20) (push) Has been cancelled
Playwright Tests / test (push) Has been cancelled
feat: enforce single active session per account
2026-04-03 17:43:03 +08:00

7 lines
311 B
SQL

ALTER TABLE "User"
ADD COLUMN IF NOT EXISTS "activeSessionKey" varchar(64),
ADD COLUMN IF NOT EXISTS "activeSessionCreatedAt" timestamp,
ADD COLUMN IF NOT EXISTS "activeSessionIp" varchar(64),
ADD COLUMN IF NOT EXISTS "activeSessionUserAgent" text,
ADD COLUMN IF NOT EXISTS "activeSessionLastSeenAt" timestamp;