Permalink
Browse files

Merge pull request #102 from PRX/oauth2_update

update for latest version of oauth2 gem
  • Loading branch information...
2 parents 36c0f9c + f92ceeb commit 480472901a9dbc9e50324f6f221163ed2f6b793e @pelle committed Apr 3, 2012
Showing with 3 additions and 3 deletions.
  1. +2 −2 lib/oauth/models/consumers/services/oauth2_token.rb
  2. +1 −1 oauth-plugin.gemspec
@@ -12,11 +12,11 @@ def self.create_consumer(options={})
def self.authorize_url(callback_url)
options = {:redirect_uri=>callback_url}
options[:scope] = credentials[:scope] if credentials[:scope].present?
- consumer.web_server.authorize_url(options)
+ consumer.auth_code.authorize_url(options)
end
def self.access_token(user, code, redirect_uri)
- access_token = consumer.web_server.get_access_token(code, :redirect_uri => redirect_uri)
+ access_token = consumer.auth_code.get_token(code, :redirect_uri => redirect_uri)
find_or_create_from_access_token user, access_token
end
View
@@ -34,6 +34,6 @@ Gem::Specification.new do |s|
s.add_dependency "multi_json"
s.add_dependency("oauth", ["~> 0.4.4"])
s.add_dependency("rack")
- s.add_dependency("oauth2")
+ s.add_dependency("oauth2", '>= 0.5.0')
end

0 comments on commit 4804729

Please sign in to comment.