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 +4 -4
- data/README.md +1 -1
- data/lib/olive_branch/middleware.rb +1 -1
- data/lib/olive_branch/version.rb +1 -1
- metadata +3 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 80f2ef38ee34ab8852a3f11c1b18310e31aeb864
|
4
|
+
data.tar.gz: 628446c9dcbd3ab769d475197a3b56cef44f6435
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
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["
|
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)
|
data/lib/olive_branch/version.rb
CHANGED
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
|
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-
|
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.
|
75
|
+
rubygems_version: 2.2.0
|
76
76
|
signing_key:
|
77
77
|
specification_version: 4
|
78
78
|
summary: Handle camel/snake/dash case conversion
|