omniauth-prx 0.0.1 → 0.0.2
Sign up to get free protection for your applications and to get access to all the features.
- data/lib/omniauth/prx/version.rb +1 -1
- data/lib/omniauth/strategies/prx.rb +14 -6
- metadata +4 -4
data/lib/omniauth/prx/version.rb
CHANGED
@@ -15,12 +15,20 @@ module OmniAuth
|
|
15
15
|
# additional calls (if the user id is returned with the token
|
16
16
|
# or as a URI parameter). This may not be possible with all
|
17
17
|
# providers.
|
18
|
-
uid
|
18
|
+
uid do
|
19
|
+
tmp = raw_info['uid']
|
20
|
+
# puts "uid: #{tmp}, raw:#{raw_info.inspect}"
|
21
|
+
tmp
|
22
|
+
end
|
19
23
|
|
20
24
|
info do
|
25
|
+
u = raw_info['info']
|
21
26
|
{
|
22
|
-
:
|
23
|
-
:
|
27
|
+
:uid => raw_info['uid'],
|
28
|
+
:login => u['login'],
|
29
|
+
:email => u['email'],
|
30
|
+
:first_name => u['first_name'],
|
31
|
+
:last_name => u['last_name']
|
24
32
|
}
|
25
33
|
end
|
26
34
|
|
@@ -36,9 +44,9 @@ module OmniAuth
|
|
36
44
|
|
37
45
|
def get_raw_info
|
38
46
|
t = access_token
|
39
|
-
puts "get_raw_info: access_token: #{t.inspect}"
|
40
|
-
r = access_token.get('/me').parsed
|
41
|
-
puts "get_raw_info: response: #{r.inspect}"
|
47
|
+
# puts "get_raw_info: access_token: #{t.inspect}"
|
48
|
+
r = access_token.get('/me', {'Accept' => 'application/json'}).parsed
|
49
|
+
# puts "get_raw_info: response: #{r.inspect}"
|
42
50
|
r
|
43
51
|
end
|
44
52
|
|
metadata
CHANGED
@@ -1,13 +1,13 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: omniauth-prx
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
hash:
|
4
|
+
hash: 27
|
5
5
|
prerelease:
|
6
6
|
segments:
|
7
7
|
- 0
|
8
8
|
- 0
|
9
|
-
-
|
10
|
-
version: 0.0.
|
9
|
+
- 2
|
10
|
+
version: 0.0.2
|
11
11
|
platform: ruby
|
12
12
|
authors:
|
13
13
|
- Andrew Kuklewicz
|
@@ -15,7 +15,7 @@ autorequire:
|
|
15
15
|
bindir: bin
|
16
16
|
cert_chain: []
|
17
17
|
|
18
|
-
date: 2011-12-
|
18
|
+
date: 2011-12-21 00:00:00 -05:00
|
19
19
|
default_executable:
|
20
20
|
dependencies:
|
21
21
|
- !ruby/object:Gem::Dependency
|