Skip to content
This repository has been archived by the owner on Jun 20, 2023. It is now read-only.

Commit

Permalink
Redifine callback_url to remove query strings
Browse files Browse the repository at this point in the history
Follow the change made in `omniauth-oauth2` gem v1.4.0,
  omniauth/omniauth-oauth2@2615267
  which changed OmniAuth::Strategies::OAuth2#callback_url to include query
  strings, while it is used to create `redirect_uri`, which should not
  include querey strings.

As omniauth/omniauth-oauth2#81
   ( especially omniauth/omniauth-oauth2#81 (comment) )
    suggests, downstream gems are to define their own `callback_url`.
  • Loading branch information
konk303 committed Feb 5, 2016
1 parent 4fc9be7 commit d47be6d
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions lib/omniauth/strategies/mixi.rb
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,10 @@ def raw_info
access_token.get('/2/people/@me/@self?fields=@all').parsed['entry']
end

def callback_url
full_host + script_name + callback_path
end

def authorize_params
super.tap do |params|
%w[display state scope].each do |v|
Expand Down

0 comments on commit d47be6d

Please sign in to comment.