Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
fix: don’t require non-casted fields
  • Loading branch information
Christian Kruse committed Jun 23, 2019
1 parent 162613e commit 005c37a
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/cforum/accounts/user.ex
Expand Up @@ -66,7 +66,7 @@ defmodule Cforum.Accounts.User do
])
|> cast_assoc(:settings)
|> cast_attachments(params, [:avatar_file_name])
|> validate_required([:username, :email, :admin, :active])
|> validate_required([:username, :email])
|> unique_constraint(:username, name: :users_username_idx)
|> unique_constraint(:email, name: :users_email_idx)
|> unique_constraint(:unconfirmed_email)
Expand Down

0 comments on commit 005c37a

Please sign in to comment.