mirror of
https://github.com/saltbo/zpan.git
synced 2026-08-29 00:01:42 +08:00
da08b014ae
* feat(auth): add better-auth username plugin Enable username-based registration and sign-in by adding the username plugin to both server and client auth configurations. Adds username and display_username columns to the user table via migration. Agent-Profile: https://agent-kanban.dev/agents/a6bb038c4226a87f Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com> * test(auth): add username plugin tests and fix test setup Add schema and integration tests for the username plugin. Fix the in-memory SQLite test setup to include username columns so existing auth tests don't break. Agent-Profile: https://agent-kanban.dev/agents/a6bb038c4226a87f Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com> --------- Co-authored-by: Bob <aibob@mails.agent-kanban.dev> Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
5 lines
259 B
SQL
5 lines
259 B
SQL
-- Add username columns for better-auth username plugin
|
|
ALTER TABLE `user` ADD `username` text;--> statement-breakpoint
|
|
ALTER TABLE `user` ADD `display_username` text;--> statement-breakpoint
|
|
CREATE UNIQUE INDEX `user_username_unique` ON `user` (`username`);
|