Undefined method `to' for nil:NilClass + devise + rails -
i using devise in rails application. users getting kind of error:
undefined method 'to' nil:nilclass method
def http_auth_header? devise.mappings[scope].to.http_authenticatable && !request.xhr? end that devise itself.
how can resolve this?
i spent time prepare same issue.
i did custom stuff sessioncontroller :
resource = warden.authenticate!(:scope => "user", :recall => "#{controller_path}#failure") and in fact, scope must be symbol :
resource = warden.authenticate!(:scope => :user, :recall => "#{controller_path}#failure") so think provide scope string instead of symbol
hope helps ;)
ruby-on-rails devise
No comments:
Post a Comment