http_api_client 0.2.0 → 0.2.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.
data/README.md CHANGED
@@ -162,3 +162,8 @@ This will install `/usr/local/opt/curl-ca-bundle/share/ca-bundle.crt`
162
162
  ### 0.1.5 - 2014-04-08
163
163
  * Logging and metrics are separate concerns and both are injectable
164
164
 
165
+ ### 0.2.0 - 2014-04-08
166
+ * 422's are now treated as exceptional which allows much easier use of http_api_client when not using Hooroo Api Tools. This moved some responsibility away from http_api_client into HoorooApiTools
167
+
168
+ ### 0.2.1 - 2014-04-08
169
+ * A couple of code cleanup actions
@@ -107,10 +107,6 @@ module HttpApiClient
107
107
  Integer(response.status).between?(200, 299)
108
108
  end
109
109
 
110
- def validation_failed?(response)
111
- Integer(response.status) == 422
112
- end
113
-
114
110
  def full_path(path)
115
111
  path = "/#{config.base_uri}/#{path}".gsub(/\/+/, '/')
116
112
  path
@@ -36,7 +36,7 @@ module HttpApiClient
36
36
  class UnknownStatus < BaseError ; end
37
37
  class UnprocessableEntity < BaseError
38
38
  def as_json
39
- Oj.load(response_body)
39
+ Oj.strict_load(response_body)
40
40
  end
41
41
  end
42
42
  class TooManyRequests < BaseError ; end
@@ -1,5 +1,5 @@
1
1
  # encoding: utf-8
2
2
 
3
3
  module HttpApiClient
4
- VERSION = "0.2.0"
4
+ VERSION = "0.2.1"
5
5
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: http_api_client
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.0
4
+ version: 0.2.1
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors: