You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
NameError (undefined local variable or method `resource_name' for #<Api::V1::Controller:0x00007fd1be55ed70>
Did you mean? resource_class):
devise_token_auth (1.1.2) app/controllers/devise_token_auth/concerns/resource_finder.rb:35:in `resource_class'
devise_token_auth (1.1.2) app/controllers/devise_token_auth/concerns/set_user_by_token.rb:106:in `update_auth_header'
Environmental Info: User record was invalid straight from database because of wrong validation.
When record is invalid straight from database, then error should be more descriptive. This stacktrace does not say what is the problem.
I fixed validations and records are now valid and everything is working flawlessly but neverless it would be nice for devise_token_auth to raise communicative errors.
The text was updated successfully, but these errors were encountered:
I'm having the same issue, it can be triggered with an invalid password_confirmation for example.
Maybe using @resource.class instead of resource_class() would be a good way to fix the issue ?
I added a resource_name method to my controller in the meantime.
When record is invalid straight from database, then error should be more descriptive. This stacktrace does not say what is the problem.
I fixed validations and records are now valid and everything is working flawlessly but neverless it would be nice for
devise_token_auth
to raise communicative errors.The text was updated successfully, but these errors were encountered: