mirror of
https://github.com/OpenAPITools/openapi-generator.git
synced 2025-07-05 15:10:49 +00:00
Fixed bug: basePath should not be empty
This last change was producing a wrong swagger spec @see https://github.com/OAI/OpenAPI-Specification/blob/master/versions/2.0.md "The value MUST start with a leading slash (/)"
This commit is contained in:
parent
170bde65e5
commit
b6e8ad56b5
@ -246,9 +246,6 @@ public class NodeJSServerCodegen extends DefaultCodegen implements CodegenConfig
|
|||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void preprocessSwagger(Swagger swagger) {
|
public void preprocessSwagger(Swagger swagger) {
|
||||||
if ("/".equals(swagger.getBasePath())) {
|
|
||||||
swagger.setBasePath("");
|
|
||||||
}
|
|
||||||
|
|
||||||
String host = swagger.getHost();
|
String host = swagger.getHost();
|
||||||
String port = "8080";
|
String port = "8080";
|
||||||
|
Loading…
x
Reference in New Issue
Block a user