-1

我在omniauth-facebook/lib/omniauth/strategies/facebook.rb 看到了这段代码

require 'omniauth/strategies/oauth2'
require 'base64'
require 'openssl'
require 'rack/utils'

module OmniAuth
  module Strategies
    class Facebook < OmniAuth::Strategies::OAuth2
      ...
    end
  end
end

问题是命名空间“ OmniAuth::Strategies::OAuth2”在哪里,它是从哪里继承的class Facebook

4

1 回答 1

1

如果此代码运行良好,那么您Gemfile可能包含omniauth-oauth2gem。这是它的定义:https ://github.com/intridea/omniauth-oauth2/blob/master/lib/omniauth/strategies/oauth2.rb

于 2013-03-20T11:13:07.687 回答