diff --git a/build/swagger-inline.js b/build/swagger-inline.js index f1db8c9..dc4f075 100644 --- a/build/swagger-inline.js +++ b/build/swagger-inline.js @@ -108,7 +108,7 @@ function swaggerInline(globPatterns, providedOptions) { schemas = _.concat(schemas, scheme); return Promise.resolve(); } catch (e) { - return Promise.reject(new Error(e.toString(), fileInfo.fileName)); + return Promise.reject(new Error("".concat(e.toString(), " \n at ").concat(fileInfo.fileName))); } })).then(function () { log("".concat(endpoints.length, " definitions found...")); diff --git a/src/swagger-inline.js b/src/swagger-inline.js index de4c724..07d195e 100644 --- a/src/swagger-inline.js +++ b/src/swagger-inline.js @@ -99,7 +99,7 @@ function swaggerInline(globPatterns, providedOptions) { schemas = _.concat(schemas, scheme); return Promise.resolve(); } catch (e) { - return Promise.reject(new Error(e.toString(), fileInfo.fileName)); + return Promise.reject(new Error(`${e.toString()} \n at ${fileInfo.fileName}`)); } }) )