ci_block_io 1.6.0 → 1.7.0
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/lib/ci_block_io/version.rb +1 -1
- data/lib/ci_block_io.rb +9 -2
- metadata +2 -2
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 2abd2718e9c87fb33dc7aaecc59c39b475fd2d99c04738fb1f9334bd3e40c861
|
|
4
|
+
data.tar.gz: 47a1b5f23851a355378cd89f50e07ef2090585d60653037bee1fbcdf78619ddf
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: ce7c50a375b4ec74ca6ff03714b23fe7cde4a30fb29739f392ecb8423345b989be3f08c7fc3cf552ed4bcb6269098b2b25f617e839b6504ef7d3bb98a8087174
|
|
7
|
+
data.tar.gz: e764bb64d1b075e8df6f6a360e952b82d0cb58786a05e6bfe4660e57e080d8c3cae15264a2b5b32914c618a43d82451d7a332170d9f3e249f3790281809394ef
|
data/lib/ci_block_io/version.rb
CHANGED
data/lib/ci_block_io.rb
CHANGED
|
@@ -8,7 +8,7 @@ require 'pbkdf2'
|
|
|
8
8
|
require 'securerandom'
|
|
9
9
|
require 'base64'
|
|
10
10
|
|
|
11
|
-
class CiBlockIoWithdrawException <
|
|
11
|
+
class CiBlockIoWithdrawException < StandardError
|
|
12
12
|
end
|
|
13
13
|
|
|
14
14
|
module CiBlockIo
|
|
@@ -148,7 +148,14 @@ module CiBlockIo
|
|
|
148
148
|
|
|
149
149
|
begin
|
|
150
150
|
body = Oj.load(response.body)
|
|
151
|
-
|
|
151
|
+
return unless body['status'].eql?('success')
|
|
152
|
+
case endpoint[0]
|
|
153
|
+
when 'withdraw' then
|
|
154
|
+
raise CiBlockIoWithdrawException.new(body['data']['error_message'])
|
|
155
|
+
else
|
|
156
|
+
raise Exception.new(body['data']['error_message'])
|
|
157
|
+
end
|
|
158
|
+
end
|
|
152
159
|
rescue
|
|
153
160
|
raise Exception.new('Unknown error occurred. Please report this.')
|
|
154
161
|
end
|
metadata
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: ci_block_io
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 1.
|
|
4
|
+
version: 1.7.0
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Atsuhiro Tsuruta feat. Atif Nazir
|
|
8
8
|
autorequire:
|
|
9
9
|
bindir: bin
|
|
10
10
|
cert_chain: []
|
|
11
|
-
date: 2018-09-
|
|
11
|
+
date: 2018-09-24 00:00:00.000000000 Z
|
|
12
12
|
dependencies:
|
|
13
13
|
- !ruby/object:Gem::Dependency
|
|
14
14
|
name: bundler
|