We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents 2196f9e + 0441de8 commit 7cf0eb1Copy full SHA for 7cf0eb1
src/parser/openapi3/body.js
@@ -163,11 +163,11 @@ module.exports = function() {
163
}
164
result = _.merge(result, merged)
165
} else if ( _.isArray(schema[i]) && i !== 'required') {
166
- const arrayResult = []
167
- for (let k in schema[i]) {
168
- arrayResult.push(replaceAllOfs(schema[i][k]))
+ if (schema[i].every(v => !_.isObject(v))) {
+ result[i] = [...schema[i]];
+ } else {
169
+ result[i] = schema[i].map(item => replaceAllOfs(item));
170
- result[i] = arrayResult
171
} else if ( _.isObject(schema[i]) && i !== 'required') {
172
// result.type = 'object';
173
result[i] = _.merge(result[i],replaceAllOfs(schema[i]))
0 commit comments