boogle 0.1.0 → 0.1.1

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,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 240af5c6cda7443ced93e8e4f40cc361bf1f7cf2
4
- data.tar.gz: aadf3010e3b63d7f39188284dfb163af1c85f674
3
+ metadata.gz: 68433670568e1771cb27d1910140be014b7fc3ae
4
+ data.tar.gz: 1465b6deff875dde7608f51fedcfe3210a4b539e
5
5
  SHA512:
6
- metadata.gz: 1a1b13067929259131a322bab92ed214fdfb0b86cedb2f07c9e0848dc919dab019fc216e2c7b948f9396fbaa75ac52d10c604299cccfab86c15f24ed952c0b8a
7
- data.tar.gz: 137ac017c58ee136fcb90773247231f54521a1d913246f74d7e03601e5503b56e0e6797c3ba3f7b2e77fadf8926e0f312b5aff028bf3b533b03b2e75fea4e030
6
+ metadata.gz: c2e55b1e2c762afa6396e621659f0a24e4f935e095662047870fa3ccad1854dab073672d29698a7e523e85197d721f233b86a567a6a50549f55a5c8365f8d06e
7
+ data.tar.gz: ac4e80d80dc3023a0346eeed220951acb1556c46efe96d2541b5416ff8ec636ade191c04b0f8d551aa223e84db78b2009c1667176636aef29b6ec46605757c71
data/.gitignore CHANGED
@@ -10,3 +10,6 @@
10
10
 
11
11
  # rspec failure tracking
12
12
  .rspec_status
13
+
14
+ # byebug history
15
+ .byebug_history
@@ -13,5 +13,7 @@ require 'boogle/traits/bookshelf'
13
13
  require 'boogle/volume'
14
14
  require 'boogle/bookshelf'
15
15
 
16
+ #errors
17
+ require 'boogle/errors'
16
18
  module Boogle
17
19
  end
@@ -5,16 +5,16 @@ module Boogle
5
5
  class BadRequest < BoogleErrors; end
6
6
  # 400: Invalid Sharing Request
7
7
  # 401: Invalid Credentials
8
- class InvalidCredentials < BoogleError; end
8
+ class InvalidCredentials < BoogleErrors; end
9
9
  # 403: Daily Limit Exceeded
10
10
  # 403: User Rate Limit Exceeded
11
11
  # 403: Rate Limit Exceeded
12
12
  # 403: Sharing Rate Limit Exceeded
13
- class LimitExceedeed < BoogleError; end
13
+ class LimitExceedeed < BoogleErrors; end
14
14
  # 404: resource not found: {fileId}
15
- class ResourceNotFound < BoogleError; end
15
+ class ResourceNotFound < BoogleErrors; end
16
16
  # 429: Too Many Requests
17
- class TooManyRequests < BoogleError; end
17
+ class TooManyRequests < BoogleErrors; end
18
18
  # 500: Backend Error
19
- class UnexpectedError < BoogleError; end
19
+ class UnexpectedError < BoogleErrors; end
20
20
  end
@@ -1,5 +1,3 @@
1
- require 'byebug'
2
-
3
1
  module Boogle
4
2
  module Service
5
3
  class Request
@@ -15,7 +13,7 @@ module Boogle
15
13
  req.url path
16
14
  req.headers['Authorization'] = auth_token
17
15
  end
18
- response.status == 200 ? true : errors(response)
16
+ response.status == 204 ? true : errors(response)
19
17
  end
20
18
 
21
19
  def remove(auth_token, key, path)
@@ -23,7 +21,7 @@ module Boogle
23
21
  req.url path
24
22
  req.headers['Authorization'] = auth_token
25
23
  end
26
- response.status == 200 ? true : errors(response)
24
+ response.status == 204 ? true : errors(response)
27
25
  end
28
26
 
29
27
  def clear(auth_token, key, path)
@@ -31,7 +29,7 @@ module Boogle
31
29
  req.url path
32
30
  req.headers['Authorization'] = auth_token
33
31
  end
34
- response.status == 200 ? true : errors(response)
32
+ response.status == 204 ? true : errors(response)
35
33
  end
36
34
 
37
35
  def search(key, path, params)
@@ -1,3 +1,3 @@
1
1
  module Boogle
2
- VERSION = "0.1.0"
2
+ VERSION = "0.1.1"
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: boogle
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.0
4
+ version: 0.1.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - HassanTC
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2017-12-05 00:00:00.000000000 Z
11
+ date: 2017-12-08 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: faraday