mirror of
https://github.com/postmanlabs/openapi-to-postman.git
synced 2022-11-29 22:05:00 +03:00
add multiple versions support
add multiple versions support
This commit is contained in:
committed by
Erik Mendoza
parent
36e83721dd
commit
30cc74b720
@@ -52,9 +52,13 @@ class SchemaPack {
|
||||
this.computedOptions.schemaFaker = true;
|
||||
let indentCharacter = this.computedOptions.indentCharacter;
|
||||
this.computedOptions.indentCharacter = indentCharacter === 'tab' ? '\t' : ' ';
|
||||
concreteUtils = getConcreteSchemaUtils(input);
|
||||
this.hasDefinedVersion = concreteUtils !== undefined;
|
||||
|
||||
try {
|
||||
this.hasDefinedVersion = true;
|
||||
concreteUtils = getConcreteSchemaUtils(input);
|
||||
}
|
||||
catch (error) {
|
||||
this.hasDefinedVersion = false;
|
||||
}
|
||||
|
||||
this.validate();
|
||||
}
|
||||
@@ -631,7 +635,8 @@ class SchemaPack {
|
||||
});
|
||||
}
|
||||
adaptedInput = schemaUtils.mapDetectRootFilesInputToGetRootFilesInput(input);
|
||||
rootFiles = parse.getRootFiles(adaptedInput, concreteUtils.inputValidation, this.computedOptions, files);
|
||||
rootFiles = parse.getRootFiles(adaptedInput, concreteUtils.inputValidation, this.computedOptions, files,
|
||||
input.specificationVersion);
|
||||
res = schemaUtils.mapGetRootFilesOutputToDetectRootFilesOutput(rootFiles, input.specificationVersion);
|
||||
return res;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user