mirror of
https://github.com/Redocly/redoc.git
synced 2025-02-07 13:30:33 +03:00
commit
8a395d268c
|
@ -56,7 +56,8 @@ export class SpecManager {
|
||||||
}
|
}
|
||||||
|
|
||||||
let host = this._schema.host || urlParts.host;
|
let host = this._schema.host || urlParts.host;
|
||||||
this.apiUrl = protocol + '://' + host + this._schema.basePath;
|
let basePath = this._schema.basePath || '/';
|
||||||
|
this.apiUrl = protocol + '://' + host + basePath;
|
||||||
if (this.apiUrl.endsWith('/')) {
|
if (this.apiUrl.endsWith('/')) {
|
||||||
this.apiUrl = this.apiUrl.substr(0, this.apiUrl.length - 1);
|
this.apiUrl = this.apiUrl.substr(0, this.apiUrl.length - 1);
|
||||||
}
|
}
|
||||||
|
|
|
@ -14,7 +14,6 @@
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"host": "petstore.swagger.io",
|
"host": "petstore.swagger.io",
|
||||||
"basePath": "/v2/",
|
|
||||||
"schemes": ["http"],
|
"schemes": ["http"],
|
||||||
"paths": {
|
"paths": {
|
||||||
"/pet": {
|
"/pet": {
|
||||||
|
|
Loading…
Reference in New Issue
Block a user