rack-json_schema 1.0.2 → 1.0.3
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +3 -0
- data/bin/specup +1 -1
- data/lib/rack/json_schema.rb +0 -1
- data/lib/rack/json_schema/error.rb +1 -1
- data/lib/rack/json_schema/mock.rb +1 -1
- data/lib/rack/json_schema/request_validation.rb +3 -3
- data/lib/rack/json_schema/response_validation.rb +1 -1
- data/lib/rack/json_schema/schema_provider.rb +1 -1
- data/lib/rack/json_schema/version.rb +1 -1
- data/rack-json_schema.gemspec +0 -1
- metadata +2 -16
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 5e80c53d0d282d68127eb359e681eff4c2d44c66
|
4
|
+
data.tar.gz: 2f7c3a9358f5bd61050d46659d78303875650122
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 996a3985a0b8b7f9aef82b4d061c50e482cf1ec2fb5a9cf0bc8f1855ff1dd74478eba661a09140418c4d33403ed96377f1642437c4ae77c3578a62e8eba192bf
|
7
|
+
data.tar.gz: 9f719f845cbd9957cc6790beb8269092b249ab2c9fc711ee8a5235d13744c3637d6ca4e580fbdc1822b31355f6c6cb229b7d7026d97c76ec3b65734f2b117fb7
|
data/CHANGELOG.md
CHANGED
data/bin/specup
CHANGED
data/lib/rack/json_schema.rb
CHANGED
@@ -50,7 +50,7 @@ module Rack
|
|
50
50
|
def has_valid_json?
|
51
51
|
parameters
|
52
52
|
true
|
53
|
-
rescue
|
53
|
+
rescue JSON::JSONError
|
54
54
|
false
|
55
55
|
end
|
56
56
|
|
@@ -108,11 +108,11 @@ module Rack
|
|
108
108
|
end
|
109
109
|
|
110
110
|
# @return [Hash] Request parameters decoded from JSON
|
111
|
-
# @raise [
|
111
|
+
# @raise [JSON::JSONError]
|
112
112
|
def parameters
|
113
113
|
@parameters ||= begin
|
114
114
|
if has_body?
|
115
|
-
|
115
|
+
JSON.parse(body)
|
116
116
|
else
|
117
117
|
{}
|
118
118
|
end
|
data/rack-json_schema.gemspec
CHANGED
@@ -19,7 +19,6 @@ Gem::Specification.new do |spec|
|
|
19
19
|
|
20
20
|
spec.add_dependency "jdoc", ">= 0.0.3"
|
21
21
|
spec.add_dependency "json_schema"
|
22
|
-
spec.add_dependency "multi_json"
|
23
22
|
spec.add_dependency "rack"
|
24
23
|
spec.add_development_dependency "bundler", "~> 1.5"
|
25
24
|
spec.add_development_dependency "pry"
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: rack-json_schema
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.0.
|
4
|
+
version: 1.0.3
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Ryo Nakamura
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2014-06-
|
11
|
+
date: 2014-06-10 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: jdoc
|
@@ -38,20 +38,6 @@ dependencies:
|
|
38
38
|
- - ">="
|
39
39
|
- !ruby/object:Gem::Version
|
40
40
|
version: '0'
|
41
|
-
- !ruby/object:Gem::Dependency
|
42
|
-
name: multi_json
|
43
|
-
requirement: !ruby/object:Gem::Requirement
|
44
|
-
requirements:
|
45
|
-
- - ">="
|
46
|
-
- !ruby/object:Gem::Version
|
47
|
-
version: '0'
|
48
|
-
type: :runtime
|
49
|
-
prerelease: false
|
50
|
-
version_requirements: !ruby/object:Gem::Requirement
|
51
|
-
requirements:
|
52
|
-
- - ">="
|
53
|
-
- !ruby/object:Gem::Version
|
54
|
-
version: '0'
|
55
41
|
- !ruby/object:Gem::Dependency
|
56
42
|
name: rack
|
57
43
|
requirement: !ruby/object:Gem::Requirement
|