olive_branch 1.0.1 → 1.1.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 57c893d626504869e2eacd978f3f267545f8e84b
4
- data.tar.gz: 020ffd7265062ac8bf6fa461eaf00102fa14f923
3
+ metadata.gz: 80f2ef38ee34ab8852a3f11c1b18310e31aeb864
4
+ data.tar.gz: 628446c9dcbd3ab769d475197a3b56cef44f6435
5
5
  SHA512:
6
- metadata.gz: b14b69a93aa6f614cb47c7b1f7755953aae47cfb97652a520a1959b74bb2af468212fb047f2d09d92ab6fea85625985b0a6aa2084d0fe63835669bf60b31d492
7
- data.tar.gz: c01c628795936ba94a4da782eb4a3a41b7b1269419e24c743d83876336c5ede5082e20be964a060b3ee9f5d33213d38f6040e65dd096624a3c43451da5a77995
6
+ metadata.gz: 99a516a13d253685f2932fc8aac9fe5c75ac4398aa237311866414d5cbcbd016092ba5f50b4d4efa8d7275c4e05c57ad0e384c817e40a982627d719156514a8d
7
+ data.tar.gz: ba1f90bd3f29d8ade69576e3ae0b8321a97299bfd14bcf3b70f2f62504a3be7437bba3223898fbb60b12a2eeb829e7f1beac2566843cc639ee3f9ef3a56b65bc
data/README.md CHANGED
@@ -16,7 +16,7 @@ This gem lets your API users pass in and receive camelCased or dash-cased keys,
16
16
 
17
17
  ## Use
18
18
 
19
- Include a `Key-Inflection` header with values of `camel`, `dash`, or `snake` in your JSON API requests.
19
+ Include a `X-Key-Inflection` header with values of `camel`, `dash`, or `snake` in your JSON API requests.
20
20
 
21
21
 
22
22
  * * *
@@ -5,7 +5,7 @@ module OliveBranch
5
5
  end
6
6
 
7
7
  def call(env)
8
- inflection = env["HTTP_KEY_INFLECTION"]
8
+ inflection = env["HTTP_X_KEY_INFLECTION"]
9
9
 
10
10
  if inflection && env["CONTENT_TYPE"] =~ /application\/json/
11
11
  env["action_dispatch.request.request_parameters"].deep_transform_keys!(&:underscore)
@@ -1,3 +1,3 @@
1
1
  module OliveBranch
2
- VERSION = '1.0.1'
2
+ VERSION = '1.1.0'
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: olive_branch
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.1
4
+ version: 1.1.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Eli Fatsi
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2016-04-14 00:00:00.000000000 Z
12
+ date: 2016-04-20 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: rails
@@ -72,7 +72,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
72
72
  version: '0'
73
73
  requirements: []
74
74
  rubyforge_project:
75
- rubygems_version: 2.2.2
75
+ rubygems_version: 2.2.0
76
76
  signing_key:
77
77
  specification_version: 4
78
78
  summary: Handle camel/snake/dash case conversion