Closed aisensiy closed 6 years ago
Could you please give more information about this error? Thanks.
I want to integration devise omniauth and weibo_2 together. I follow the README and write
config.omniauth :weibo, Settings.WEIBO_KEY, Settings.WEIBO_SECRET, :scope => 'follow_app_official_microblog'
in file config/initiallizers/devise.rb
. But when i run command rails s
in development environment. It show the errors above.
Thanks, I will follow up this issue later.
It because Devise.omniauth_configs[:weibo].strategy
is nil
even all Devise.omniauth_configs. but you can fetch the key "args", check the Devise.omniauth_configs dump:
{
:weibo => #<Devise::OmniAuth::Config:0x007fe10ddf0048 @provider=:weibo, @args=["cliend_id", "client_secret", {:scope=>"user,public_repo"}], @options={:scope=>"user"}, @strategy=nil, @strategy_name=:weibo, @strategy_class=nil>
}
Test env: rails 4.0 / devise 3.2.2 / omniauth-oauth-weibo2 0.3.0
@icyleaf Thanks for updating this, would you like to open a pull to fix this?