@stoplight/spectral-core
Advanced tools
Comparing version 1.10.2 to 1.11.0
@@ -6,2 +6,3 @@ "use strict"; | ||
const lodash_1 = require("lodash"); | ||
const pony_cause_1 = require("pony-cause"); | ||
const document_1 = require("../document"); | ||
@@ -22,6 +23,14 @@ const utils_1 = require("./utils"); | ||
const path = target.path.length > 0 ? [...givenPath, ...target.path] : givenPath; | ||
const targetResults = then.function(target.value, (_a = then.functionOptions) !== null && _a !== void 0 ? _a : null, { | ||
...fnContext, | ||
path, | ||
}); | ||
let targetResults; | ||
try { | ||
targetResults = then.function(target.value, (_a = then.functionOptions) !== null && _a !== void 0 ? _a : null, { | ||
...fnContext, | ||
path, | ||
}); | ||
} | ||
catch (e) { | ||
throw new pony_cause_1.ErrorWithCause(`Function "${then.function.name}" threw an exception${(0, lodash_1.isError)(e) ? `: ${e.message}` : ''}`, { | ||
cause: e, | ||
}); | ||
} | ||
if (targetResults === void 0) | ||
@@ -28,0 +37,0 @@ continue; |
{ | ||
"name": "@stoplight/spectral-core", | ||
"version": "1.10.2", | ||
"version": "1.11.0", | ||
"main": "dist/index.js", | ||
@@ -43,2 +43,3 @@ "types": "dist/index.d.ts", | ||
"nimma": "0.1.8", | ||
"pony-cause": "^1.0.0", | ||
"simple-eval": "1.0.0", | ||
@@ -45,0 +46,0 @@ "tslib": "^2.3.0" |
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
166570
2530
21
+ Addedpony-cause@^1.0.0
+ Addedpony-cause@1.1.1(transitive)