omniauth-surveymonkey 2.0.0 → 2.0.1

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
  SHA1:
3
- metadata.gz: 3e0429659fff91c97567414014c2ce50de993080
4
- data.tar.gz: 4e274dd1478e0e2c122870adbb38d24ba681462e
3
+ metadata.gz: 99380794188f8ce8decc2b5c5ce62916ac53f46e
4
+ data.tar.gz: c82ce23a2418424ee88031e03622fa3c0c8538b6
5
5
  SHA512:
6
- metadata.gz: 9618956d081f2bd90d2f6944dc22cf75da39b1f3fccd7bc443a6f459bc9dc2ab8379e709e5c93e86bd5a150934cb9f6dd037bf6363930d39223516b9b0f3b705
7
- data.tar.gz: 63130a67d60ea4e7d56e33cbd78d498b2d49531f2ecf21140e18fa4669a1badaad0722c2e778a1220a7da38803c6d837b9ff84c21ab8d3314e92d654c9e78a23
6
+ metadata.gz: 122f40ce750e893832b7168dc1f7adc09844bb474eb6695a5aad0581e0a3493c407a3f54099357838d07fa0ec9f9b5748a9bc0288db134ac7d1db597b4779b6f
7
+ data.tar.gz: 8c97898e4bac865d3c29406d995e088cc05df09aa22614f7e9913088a92ee3d801ea6dc8fcb2a5ad2bc24936167934cc24b84efadf05884f6c24cda2627a164a
@@ -1,5 +1,5 @@
1
1
  module OmniAuth
2
2
  module SurveyMonkey
3
- VERSION = '2.0.0'
3
+ VERSION = '2.0.1'
4
4
  end
5
5
  end
@@ -32,17 +32,19 @@ module OmniAuth
32
32
  json = ::MultiJson.load response.body
33
33
  options.access_token = json['access_token']
34
34
 
35
- connection.authorization :Bearer, options.access_token
36
- info = connection.get "/v3/users/me?api_key=#{options.api_key}"
37
- json = ::MultiJson.load info.body
35
+ if options.access_token
36
+ connection.authorization :Bearer, options.access_token
37
+ info = connection.get "/v3/users/me?api_key=#{options.api_key}"
38
+ json = ::MultiJson.load info.body
38
39
 
39
- options.username = json['username']
40
- options.first_name = json['first_name']
41
- options.last_name = json['last_name']
42
- options.account_type = json['account_type']
43
- options.language = json['language']
44
- options.email = json['email']
45
- options.surveymonkey_id = json['id'].to_i
40
+ options.username = json['username']
41
+ options.first_name = json['first_name']
42
+ options.last_name = json['last_name']
43
+ options.account_type = json['account_type']
44
+ options.language = json['language']
45
+ options.email = json['email']
46
+ options.surveymonkey_id = json['id'].to_i
47
+ end
46
48
 
47
49
  super
48
50
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: omniauth-surveymonkey
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.0.0
4
+ version: 2.0.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Jordan McKible
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2016-07-05 00:00:00.000000000 Z
11
+ date: 2016-08-18 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: omniauth
@@ -134,7 +134,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
134
134
  version: '0'
135
135
  requirements: []
136
136
  rubyforge_project:
137
- rubygems_version: 2.6.6
137
+ rubygems_version: 2.5.1
138
138
  signing_key:
139
139
  specification_version: 4
140
140
  summary: OmniAuth strategy for the SurveyMonkey developer API