社交登錄正在開發中,但一旦推到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
我已經達到了我的調試路障。有什麼想法嗎?調試想法?類似的體驗?
你有一些變量爲零,當它不應該。每次通話在哪裏?但很可能你忘了配置你的生產環境;) –