Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

devise: "Reset password token is invalid" message

I'm using devise 2.0.4 and cannot find where the "Reset password token is invalid" message is defined. I would have thought it was in the locales YAML file but it is not. I've also searched the gem source to no avail, which leads me to think that it must be constructed at run time. In the devise_error_messages! method I see that it must be defined as one of the full_messages for the resource, but being somewhat of a rails newbie I'm not sure where to look for that.

like image 319
mcoomey Avatar asked Dec 12 '25 22:12

mcoomey


1 Answers

Put this in your config/locales/en.yml

en:
  activerecord:
    errors:
      models:
        user:
          attributes:
            reset_password_token:
              blank: "is not valid"
              invalid: "is not valid"
like image 142
David Avatar answered Dec 15 '25 12:12

David



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!