omniauth-expressov3 1.0.5 → 1.0.6
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml
CHANGED
@@ -1,15 +1,15 @@
|
|
1
1
|
---
|
2
2
|
!binary "U0hBMQ==":
|
3
3
|
metadata.gz: !binary |-
|
4
|
-
|
4
|
+
OTVhZTJlYWJiNTQ3M2M1NDhlNDQ4NmExMWQ1Zjg5NjZjNzNkZTEwNw==
|
5
5
|
data.tar.gz: !binary |-
|
6
|
-
|
6
|
+
YjNlZmYyOTkyYWYyMjI1YTM3YjZkMDViOGJjMjI1NjkxOWRmNTM5Mw==
|
7
7
|
SHA512:
|
8
8
|
metadata.gz: !binary |-
|
9
|
-
|
10
|
-
|
11
|
-
|
9
|
+
YjZhZGZmYzM2ZjcxNTQ4ZTExYTMyMWNmNDdmNDIzOTc3OWFlNWY4YWUxZmIw
|
10
|
+
ZjVkMmZjZDhmOWZmZjRlNThkNjY3NTk3OGRmMGZjMThlMTJkZGVmY2I4MjAx
|
11
|
+
Zjk1Zjc0MGY4NzdiMTBhYmVmNTdjMWI5YjBkNjc0NDdjOTVjNGE=
|
12
12
|
data.tar.gz: !binary |-
|
13
|
-
|
14
|
-
|
15
|
-
|
13
|
+
MjYxYTQxZjQ2ZDczMDhmODA3MjkxMGE2ZGUyNGU0NThjMzk4MjAyYWUxNzI0
|
14
|
+
MWZlYTQwMGExMmVmMTkzNGU3M2M5NmIxZWE1NjNlNTRlYmNkYWQ4ODFjYjA2
|
15
|
+
ZDU4NmRhYTJmMjQ1OTZkOGE0MDIyOGUyMWU5ODQyYzc4YjZmZjQ=
|
@@ -43,6 +43,7 @@ module OmniAuth
|
|
43
43
|
end
|
44
44
|
|
45
45
|
def callback_phase
|
46
|
+
|
46
47
|
@auth_client = OmniAuth::ExpressoV3::AuthClient.new @options
|
47
48
|
|
48
49
|
return fail!(:missing_credentials) if missing_credentials?
|
@@ -57,6 +58,7 @@ module OmniAuth
|
|
57
58
|
|
58
59
|
super
|
59
60
|
rescue Exception => e
|
61
|
+
puts "#{e.message} -\n\t#{e.backtrace}"
|
60
62
|
return fail!(:expressov3_error, e)
|
61
63
|
end
|
62
64
|
end
|
@@ -3,9 +3,9 @@ module OmniAuth
|
|
3
3
|
module ExpressoV3
|
4
4
|
class AuthClient
|
5
5
|
|
6
|
-
class MissingArgumentsError <
|
7
|
-
class AuthenticationError <
|
8
|
-
class ConnectionError <
|
6
|
+
class MissingArgumentsError < Exception; end
|
7
|
+
class AuthenticationError < Exception; end
|
8
|
+
class ConnectionError < Exception; end
|
9
9
|
|
10
10
|
SERVICE_URL = "https://expressov3.serpro.gov.br/index.php"
|
11
11
|
|
@@ -146,7 +146,7 @@ describe "OmniAuth::Strategies::ExpressoV3" do
|
|
146
146
|
json_path = File.expand_path(File.dirname(__FILE__) + '../../../result.json')
|
147
147
|
File.open(json_path) do |f|
|
148
148
|
json = f.read
|
149
|
-
return JSON.parse(json)
|
149
|
+
return RecursiveOpenStruct.new(JSON.parse(json), :recurse_over_arrays => true)
|
150
150
|
end
|
151
151
|
}
|
152
152
|
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: omniauth-expressov3
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.0.
|
4
|
+
version: 1.0.6
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Abner Oliveira
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2015-02-
|
11
|
+
date: 2015-02-23 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: omniauth
|