diff options
author | Azul <azul@riseup.net> | 2017-03-07 21:23:11 +0100 |
---|---|---|
committer | Azul <azul@riseup.net> | 2017-03-07 21:23:11 +0100 |
commit | fddc0dab59ffc349f1d7b16b595f2f5668624525 (patch) | |
tree | bd94c0d25891d0ce8a53dbf5b7363fc9f52ee9e6 | |
parent | 67824594246aee807ebacdf61c4e2d0a136eab73 (diff) |
make the rescue in account creation less broad
It was catching errors that should have led to 500s
-rw-r--r-- | app/models/account.rb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/app/models/account.rb b/app/models/account.rb index d722caa..db4cfbe 100644 --- a/app/models/account.rb +++ b/app/models/account.rb @@ -47,7 +47,7 @@ class Account user_invite_code.save end end - rescue StandardError => ex + rescue VALIDATION_FAILED => ex user.errors.add(:base, ex.to_s) if user ensure if creation_problem?(user, identity) |