swagger-dsl 1.2.1 → 1.3.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +4 -0
- data/lib/swagger/dsl/rails_controller.rb +4 -1
- data/lib/swagger/dsl/version.rb +1 -1
- metadata +3 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: a014577228f6444f0b6f6d4b3766d8231e280b4a8d099e1676f1d3711a832bab
|
4
|
+
data.tar.gz: a8495609f16a93e3af4dfacacafc400a3f14235836dc7b49e6907afafaa287c1
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: d86adb4e85d2162ea20b5cee7f6bb99c3447a7e00a3d6ceb6d427c104e20d0819cb372664ebfcc7677c3d2854c445d5feb059ca8e56bca288e29b1f854b6ee62
|
7
|
+
data.tar.gz: b1235bc9d31acb7c2828c6e45bf3123f9f2a907079e4dee1c6008c4ebdb276d0f00ed724469dfde91f33eb2e9fc4bf030e809e14c712c255d15d99de55a91e7a
|
data/CHANGELOG.md
CHANGED
@@ -20,11 +20,14 @@ module Swagger
|
|
20
20
|
if method.include?("|")
|
21
21
|
raise NotExactMatch, "route matched but verb can be #{verb}! specify :method key like 'get'."
|
22
22
|
end
|
23
|
+
method = ["put", "patch"] if ["put", "patch"].include?(method)
|
23
24
|
path ||= route.path.spec.to_s.sub("(.:format)", "").gsub(/:(\w+)/, "{\\1}")
|
24
25
|
|
25
26
|
operation = Swagger::DSL::Operation.new(operation_id, format: format, &block)
|
26
27
|
Swagger::DSL.current["paths"][path] ||= {}
|
27
|
-
|
28
|
+
Array(method).each do |single_method|
|
29
|
+
Swagger::DSL.current["paths"][path][single_method] = operation
|
30
|
+
end
|
28
31
|
end
|
29
32
|
|
30
33
|
alias_method :oas3, :swagger
|
data/lib/swagger/dsl/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: swagger-dsl
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.
|
4
|
+
version: 1.3.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Narazaka
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2019-12-
|
11
|
+
date: 2019-12-03 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: jimmy
|
@@ -264,7 +264,7 @@ metadata:
|
|
264
264
|
homepage_uri: https://github.com/Narazaka/swagger-dsl
|
265
265
|
source_code_uri: https://github.com/Narazaka/swagger-dsl.git
|
266
266
|
changelog_uri: https://github.com/Narazaka/swagger-dsl/blob/master/CHANGELOG.md
|
267
|
-
documentation_uri: https://www.rubydoc.info/gems/swagger-dsl/1.
|
267
|
+
documentation_uri: https://www.rubydoc.info/gems/swagger-dsl/1.3.0
|
268
268
|
post_install_message:
|
269
269
|
rdoc_options: []
|
270
270
|
require_paths:
|