summaryrefslogtreecommitdiff
path: root/app/models
diff options
context:
space:
mode:
authorAzul <azul@riseup.net>2017-03-07 21:23:11 +0100
committerAzul <azul@riseup.net>2017-03-07 21:23:11 +0100
commitfddc0dab59ffc349f1d7b16b595f2f5668624525 (patch)
treebd94c0d25891d0ce8a53dbf5b7363fc9f52ee9e6 /app/models
parent67824594246aee807ebacdf61c4e2d0a136eab73 (diff)
make the rescue in account creation less broad
It was catching errors that should have led to 500s
Diffstat (limited to 'app/models')
-rw-r--r--app/models/account.rb2
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)