swaggard 1.0.0 → 1.0.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/swaggard/swagger/parameters/body.rb +1 -0
- data/lib/swaggard/swagger/property.rb +1 -0
- data/lib/swaggard/version.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: b3e1aa159808f0d01c9e6759727b97aff8a0cb4c383f441a3ca602e6b302da8b
|
4
|
+
data.tar.gz: 4f3b2511fbd15049e5e8746af31174705544a477b70cc0cbbe30d24563897ee7
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 244da8fb5d6d234aab95d0b6e1b6bf13fd1dd7f519daf93aa2ff1f21dd05e2d0a886aa1e80f07ae7181d7541fc853b83bf5f711465976577cea725175bb0be36
|
7
|
+
data.tar.gz: c82e666367b0555c8d7de02f785c9045aa53c77c591855afa5e1c093f294c8b69cff7cbcc5a9eb70cdda1004f855cf149148fede20be4f4296515878855aa34c
|
@@ -75,6 +75,7 @@ module Swaggard
|
|
75
75
|
# Example: [Array] status(required) Filter by status. (e.g. status[]=1&status[]=2&status[]=3)
|
76
76
|
# Example: [Integer] media[media_type_id] ID of the desired media type.
|
77
77
|
def parse(string)
|
78
|
+
string.gsub!("\n", ' ')
|
78
79
|
data_type, required, name, options_and_description = string.match(/\A\[(\S*)\](!)?\s*([\w\[\]]*)\s*(.*)\Z/).captures
|
79
80
|
allow_multiple = name.gsub!('[]', '')
|
80
81
|
options, description = options_and_description.match(/\A(\[.*\])?(.*)\Z/).captures
|
@@ -10,6 +10,7 @@ module Swaggard
|
|
10
10
|
name = yard_object.name.dup
|
11
11
|
options_and_description = yard_object.text&.dup || ''
|
12
12
|
|
13
|
+
options_and_description.gsub!("\n", ' ')
|
13
14
|
options, description = options_and_description.match(/\A(\[.*\])?(.*)\Z/).captures
|
14
15
|
options = options ? options.gsub(/\[?\]?\s?/, '').split(',') : []
|
15
16
|
description = description.strip
|
data/lib/swaggard/version.rb
CHANGED