omniauth-etencent 0.2.0 → 0.3.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 952ead3ed51704b1ae474021f45442f0651150df8300e7ecc58d287de2c8a867
4
- data.tar.gz: c9c8b939127dd79dc0298937fa2dec1b9115dfce7843a669615660b757871238
3
+ metadata.gz: 69da7f565b1e3c646ac1a9569cd11f5ff19c915e507d54a13e5192667eb027f3
4
+ data.tar.gz: e97d98528f351dd8cfd9838a1ddea3bbc46f71b0d66ea0d26c407d108f45add3
5
5
  SHA512:
6
- metadata.gz: 2a3c8574608303b485b4cd240fb2a529aed095900c9ff4fc7e63e581cd6230b8e7321767e6e1be0cd6cc58f936bcb2be8aea11084c4e2042e421c6fdc505d92c
7
- data.tar.gz: 07e072335074ad32352c7d8a8b3dc79f0b01990128fe4c35b43bebee53e5f08e8d82e2c01bd12f5518a14cbe9694b325bda4eda5063b2f34280d0761a709613a
6
+ metadata.gz: ec3af148ec3c52d40a76647a8eeba4325bb85b6917ba7bcee09b74dc9e77186923288c23f789dc24503e7034f8e37e630a2efc5e5d80d027e001f0bda2138cb8
7
+ data.tar.gz: ca45d7c111406271158212a11e0beb26d70b53f7b8a4363c7b8075a703261d144ee031957fffca183a338d9938fccaaa789494739a92058364a9d89dbc7abd28
data/Gemfile.lock CHANGED
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- omniauth-etencent (0.1.0)
4
+ omniauth-etencent (0.2.0)
5
5
  omniauth (~> 2.0)
6
6
  omniauth-oauth2 (~> 1.7.1)
7
7
 
@@ -1,5 +1,5 @@
1
1
  module OmniAuth
2
2
  module Etencent
3
- VERSION = "0.2.0"
3
+ VERSION = "0.3.0"
4
4
  end
5
5
  end
@@ -11,8 +11,6 @@ module OmniAuth
11
11
  extract_access_token: ::OmniAuth::Etencent::AccessToken
12
12
  }
13
13
 
14
- option :authorize_options, %i[scope state account_type account_display_number]
15
-
16
14
  option :sandbox, false
17
15
 
18
16
  def authorize_params
@@ -57,6 +55,11 @@ module OmniAuth
57
55
  authorizer_info['scope_list']
58
56
  end
59
57
 
58
+ def request_phase
59
+ session['omniauth.redirect_uri'] = callback_url
60
+ super
61
+ end
62
+
60
63
  protected
61
64
 
62
65
  def client
@@ -71,6 +74,10 @@ module OmniAuth
71
74
  def api_base_url
72
75
  options.sandbox ? 'https://sandbox-api.e.qq.com' : 'https://api.e.qq.com'
73
76
  end
77
+
78
+ def token_params
79
+ super.merge(authorization_code: request.params['authorization_code'], redirect_uri: session['omniauth.redirect_uri'])
80
+ end
74
81
  end
75
82
  end
76
83
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: omniauth-etencent
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.0
4
+ version: 0.3.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - jimcheung
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2021-06-27 00:00:00.000000000 Z
11
+ date: 2021-06-30 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: omniauth