mirror of
https://github.com/heartcombo/devise.git
synced 2022-11-09 12:18:31 -05:00
Revert "Better error message in case a trackable module can't be saved."
This reverts commit 43d0715238
.
save() returns false only when validations failed. In this case, validations are
not performed. Therefore save() may never return a falsy value.
If save() fails, the appropriate exception is raised.
With certain ORMs, such as NoBrainer, save() never returns true/false, but
always raise an exception. This commit lift the incompatiblity.
This commit is contained in:
parent
710efe557d
commit
620478cc5f
1 changed files with 1 additions and 2 deletions
|
@ -30,8 +30,7 @@ module Devise
|
|||
|
||||
def update_tracked_fields!(request)
|
||||
update_tracked_fields(request)
|
||||
save(validate: false) or raise "Devise trackable could not save #{inspect}." \
|
||||
"Please make sure a model using trackable can be saved at sign in."
|
||||
save(validate: false)
|
||||
end
|
||||
end
|
||||
end
|
||||
|
|
Loading…
Add table
Reference in a new issue