使用 OmniAuth 时出现 Nil 对象错误(通常有效)
我在使用 Omniauth 时遇到奇怪的错误。这似乎与我的代码关系不大。
这是 Twitter 返回一些奇怪的变形物体的结果吗?
You have a nil object when you didn't expect it!
You might have expected an instance of ActiveRecord::Base.
The error occurred while evaluating nil.[]
oa-oauth (0.1.6) lib/omniauth/strategies/oauth.rb:24:in `callback_phase'
oa-core (0.1.6) lib/omniauth/strategy.rb:27:in `call!'
oa-core (0.1.6) lib/omniauth/strategy.rb:19:in `call'
oa-core (0.1.6) lib/omniauth/builder.rb:30:in `call'
haml (3.0.24) lib/sass/plugin/rack.rb:41:in `call'
I am having a weird error when using Omniauth. This appears to have little to do with my code.
Is this the result of Twitter returning some weird deformed object?
You have a nil object when you didn't expect it!
You might have expected an instance of ActiveRecord::Base.
The error occurred while evaluating nil.[]
oa-oauth (0.1.6) lib/omniauth/strategies/oauth.rb:24:in `callback_phase'
oa-core (0.1.6) lib/omniauth/strategy.rb:27:in `call!'
oa-core (0.1.6) lib/omniauth/strategy.rb:19:in `call'
oa-core (0.1.6) lib/omniauth/builder.rb:30:in `call'
haml (3.0.24) lib/sass/plugin/rack.rb:41:in `call'
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
现在可以了。我高度怀疑这是Twitter的畸形回归。
It works now. I highly suspect that it is a deformed return by Twitter.
我有类似的问题。清除浏览器缓存解决了它。
懒惰型
I had a similar problem. clearing the browser cache solved it.
slothistype