open_api_import 0.8.3 → 0.8.4
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/open_api_import.rb +6 -0
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 35841345320b0ed839612396e6776c0c223b55f9ff7fd7c8c3da6e9864eb5445
|
4
|
+
data.tar.gz: 4985d72b2b526c984c97994624ef47345885269797ab45676e9bb702e4936be8
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: f709982c86e865126750f1d6474a07a9ab4bc82d62e3fe3238395965a9640f08734e615b67239c6cc93807c9c29527986f6ccb1e333bde0dab948af48515f69d
|
7
|
+
data.tar.gz: e60ba8c480bc16841c89e9daf68436649db1e6ec7fb1cb01011e360741560327efa9b7c581cdedf099489fa0765fff4b41d19cf731dde3f5b37b44154e49491f
|
data/lib/open_api_import.rb
CHANGED
@@ -748,6 +748,12 @@ class OpenApiImport
|
|
748
748
|
# for the case only type supplied but nothing else for the array
|
749
749
|
response_example << "[\"#{v[:schema][:items][:type]}\"]"
|
750
750
|
end
|
751
|
+
response_example.each do |rs|
|
752
|
+
#(@type Google) for the case in example the key is something like: @type:
|
753
|
+
if rs.match?(/^\s*@\w+:/)
|
754
|
+
rs.gsub!(/@(\w+):/,"'@\1':")
|
755
|
+
end
|
756
|
+
end
|
751
757
|
return response_example
|
752
758
|
end
|
753
759
|
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: open_api_import
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.8.
|
4
|
+
version: 0.8.4
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Mario Ruiz
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2019-08-
|
11
|
+
date: 2019-08-16 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: oas_parser
|