diff --git a/package.json b/package.json index 51be80d8..d9a0fa47 100644 --- a/package.json +++ b/package.json @@ -16,7 +16,7 @@ "format": "prettier --write .", "format:check": "prettier --check .", "lint": "eslint .", - "test": "lerna run lint --since --stream && jest" + "test": "lerna run lint --since --stream && jest --forceExit" }, "devDependencies": { "@babel/cli": "^7.11.6", diff --git a/packages/dispatchr/lib/Dispatcher.js b/packages/dispatchr/lib/Dispatcher.js index 0ef175f6..6c507d89 100644 --- a/packages/dispatchr/lib/Dispatcher.js +++ b/packages/dispatchr/lib/Dispatcher.js @@ -188,7 +188,7 @@ Dispatcher.prototype._throwOrCallErrorHandler = context ); } else { - throw new Error(message); + throw new Error(message, { cause: meta && meta.error }); } };