authy 2.6.1 → 2.6.2
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 +4 -4
- data/LICENSE.txt +1 -1
- data/README.md +1 -1
- data/lib/authy/onetouch.rb +4 -4
- data/lib/authy/version.rb +1 -1
- data/spec/authy/onetouch_spec.rb +19 -0
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: b489cbdfb4d178f484bc4c37f95cbcbd821b8945
|
4
|
+
data.tar.gz: ef2ecbef6816ca8dfdae6101cfb4257639df0255
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 2c1658d01e8ef743192782a754c9eef8b5ed4fbd0c6a6d63a01423011ce80c3c41b5e2ba188922424a51a7a6b46b2418b7c3711e57b412cb6663360820ad44bc
|
7
|
+
data.tar.gz: 22f594d2a6b50657802aa6a59989bf3014af4fac4c381805ecff92de873d1dbeb98fc1cfd33885ca8b0a03a33764755d298a2d58f168993ab017ed2c9234b22e
|
data/LICENSE.txt
CHANGED
data/README.md
CHANGED
data/lib/authy/onetouch.rb
CHANGED
@@ -29,9 +29,9 @@ module Authy
|
|
29
29
|
end
|
30
30
|
|
31
31
|
params = { message: message[0, MAX_STRING_SIZE] }
|
32
|
-
params[:details]
|
33
|
-
params[:hidden_details]
|
34
|
-
params[:logos]
|
32
|
+
params[:details] = details unless details.nil?
|
33
|
+
params[:hidden_details] = hidden_details unless hidden_details.nil?
|
34
|
+
params[:logos] = logos unless logos.nil?
|
35
35
|
params[:seconds_to_expire] = seconds_to_expire unless seconds_to_expire.nil?
|
36
36
|
|
37
37
|
post_request("onetouch/json/users/#{user_id}/approval_requests", params)
|
@@ -64,7 +64,7 @@ module Authy
|
|
64
64
|
|
65
65
|
# We ignore any additional parameter on the logos, and truncate
|
66
66
|
# string size to the maximum allowed.
|
67
|
-
{ res: res[0, MAX_STRING_SIZE], url: url[0,
|
67
|
+
{ res: res[0, MAX_STRING_SIZE], url: url[0, MAX_STRING_SIZE] }
|
68
68
|
end
|
69
69
|
end
|
70
70
|
end
|
data/lib/authy/version.rb
CHANGED
data/spec/authy/onetouch_spec.rb
CHANGED
@@ -56,6 +56,25 @@ describe Authy::OneTouch do
|
|
56
56
|
expect(response).to be_kind_of(Authy::Response)
|
57
57
|
expect(response).to be_ok
|
58
58
|
end
|
59
|
+
|
60
|
+
it 'checks logos format' do
|
61
|
+
response = Authy::OneTouch.send_approval_request(
|
62
|
+
id: @user.id,
|
63
|
+
message: 'You are moving 10 BTC from your account',
|
64
|
+
details: {
|
65
|
+
'Bank account' => '23527922',
|
66
|
+
'Amount' => '10 BTC',
|
67
|
+
},
|
68
|
+
hidden_details: {
|
69
|
+
'IP Address' => '192.168.0.3'
|
70
|
+
},
|
71
|
+
seconds_to_expire: 150,
|
72
|
+
logos: [{res: 'low', url: 'http://foo.bar'}]
|
73
|
+
)
|
74
|
+
|
75
|
+
expect(response).to be_kind_of(Authy::Response)
|
76
|
+
expect(response).to be_ok
|
77
|
+
end
|
59
78
|
end
|
60
79
|
|
61
80
|
describe '.approval_request_status' do
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: authy
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 2.6.
|
4
|
+
version: 2.6.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Authy Inc
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2016-02-09 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: httpclient
|