mirror of
https://github.com/postmanlabs/openapi-to-postman.git
synced 2022-11-29 22:05:00 +03:00
Lint fixes
This commit is contained in:
12
lib/util.js
12
lib/util.js
@@ -1208,24 +1208,24 @@ module.exports = {
|
|||||||
}
|
}
|
||||||
catch (e) {
|
catch (e) {
|
||||||
// the SDK sometimes throws an exception in url.toString :/
|
// the SDK sometimes throws an exception in url.toString :/
|
||||||
//console.error('Exception thrown while trying to stringify url for item.request:', item.request,
|
// console.error('Exception thrown while trying to stringify url for item.request.url:', item.request.url,
|
||||||
// 'Exception:', e);
|
// 'Exception:', e);
|
||||||
thisOriginalRequest.url = '';
|
thisOriginalRequest.url = '';
|
||||||
}
|
}
|
||||||
try {
|
try {
|
||||||
thisOriginalRequest.header = item.request.headers.toJSON();
|
thisOriginalRequest.header = item.request.headers.toJSON();
|
||||||
}
|
}
|
||||||
catch (e) {
|
catch (e) {
|
||||||
//console.error('Exception thrown while trying to stringify headers for item.request:', item.request,
|
// console.error('Exception thrown while trying to stringify headers for item.request.headers:',
|
||||||
// 'Exception:', e);
|
// item.request.headers, 'Exception:', e);
|
||||||
thisOriginalRequest.header = [];
|
thisOriginalRequest.header = [];
|
||||||
}
|
}
|
||||||
try {
|
try {
|
||||||
thisOriginalRequest.body = (item.request.body ? item.request.body.toJSON() : {});
|
thisOriginalRequest.body = (item.request.body ? item.request.body.toJSON() : {});
|
||||||
}
|
}
|
||||||
catch (e) {
|
catch (e) {
|
||||||
//console.error('Exception thrown while trying to json-ify body for item.request:', item.request,
|
// console.error('Exception thrown while trying to json-ify body for item.request.body:', item.request.body,
|
||||||
// 'Exception:', e);
|
// 'Exception:', e);
|
||||||
thisOriginalRequest.body = {};
|
thisOriginalRequest.body = {};
|
||||||
}
|
}
|
||||||
item.responses.add(this.convertToPmResponse(swagResponse, code, thisOriginalRequest));
|
item.responses.add(this.convertToPmResponse(swagResponse, code, thisOriginalRequest));
|
||||||
|
|||||||
Reference in New Issue
Block a user