feat(chat): validate username on registration

Also, update seeds to register with usernames.
This commit is contained in:
2025-02-15 22:15:21 +00:00
parent 10c905249c
commit b7de53bab0
3 changed files with 38 additions and 13 deletions

View File

@@ -30,7 +30,7 @@ pw = "TheFellowship"
for name <- names do
email = "#{String.downcase(name)}@fellowship.me"
Accounts.register_user(%{email: email, password: pw, password_confirmation: pw})
Accounts.register_user(%{username: name, email: email, password: pw, password_confirmation: pw})
end
aragorn = Accounts.get_user_by_email("aragorn@fellowship.me")