社交登录正在开发中,但一旦推到heroku,我得到NoMethodError (undefined method `each' for nil:NilClass)
在new
。Devise + Omniauth + Heroku在#new_with_session中的undefined方法
从我的用户模型:
def self.new_with_session(params, session)
if session["devise.user_attributes"]
new(session["devise.user_attributes"], without_protection: true) do |user|
user.attributes = params
user.valid?
end
else
super
end
end
我已经达到了我的调试路障。有什么想法吗?调试想法?类似的体验?
你有一些变量为零,当它不应该。每次通话在哪里?但很可能你忘了配置你的生产环境;) –