Revert "Fixed require_strategy for google_oauth2 omniauth strategy."

This reverts commit 065963f6d3.
This commit is contained in:
José Valim 2011-11-20 19:21:08 +00:00
parent 1e37e42239
commit dfb8ff372d
3 changed files with 2 additions and 3 deletions

View File

@ -11,7 +11,6 @@ gem "rdoc"
group :test do
gem 'omniauth-facebook'
gem 'omniauth-openid', '~> 1.0.1'
gem "omniauth-google-oauth2", '~> 0.1.4'
gem "webrat", "0.7.2", :require => false
gem "mocha", :require => false
end

View File

@ -28,7 +28,7 @@ module Devise
end
def require_strategy
if [:facebook, :github, :twitter, :google_oauth2].include?(provider.to_sym)
if [:facebook, :github, :twitter].include?(provider.to_sym)
require "omniauth/strategies/#{provider}"
elsif options[:require]
require options[:require]

View File

@ -179,7 +179,7 @@ Devise.setup do |config|
config.omniauth :facebook, 'APP_ID', 'APP_SECRET', :scope => 'email,offline_access'
config.omniauth :openid
config.omniauth :openid, :name => 'google', :identifier => 'https://www.google.com/accounts/o8/id'
config.omniauth :google_oauth2, 'APP_ID', 'APP_SECRET', :scope => 'https://www.googleapis.com/auth/userinfo.email'
# ==> Warden configuration
# If you want to use other strategies, that are not supported by Devise, or
# change the failure app, you can configure them inside the config.warden block.