Skip to content

Commit f60c26e

Browse files
committedNov 5, 2018
Switch from loud-rejection to hard-rejection
The difference is that now it will crash the process right away on unhandled promises instead of waiting until the process exits. Fixes #93
1 parent 89f8983 commit f60c26e

File tree

3 files changed

+5
-5
lines changed

3 files changed

+5
-5
lines changed
 

‎index.js

+2-2
Original file line numberDiff line numberDiff line change
@@ -7,15 +7,15 @@ const decamelizeKeys = require('decamelize-keys');
77
const trimNewlines = require('trim-newlines');
88
const redent = require('redent');
99
const readPkgUp = require('read-pkg-up');
10-
const loudRejection = require('loud-rejection');
10+
const hardRejection = require('hard-rejection');
1111
const normalizePackageData = require('normalize-package-data');
1212

1313
// Prevent caching of this module so module.parent is always accurate
1414
delete require.cache[__filename];
1515
const parentDir = path.dirname(module.parent.filename);
1616

1717
module.exports = (helpMessage, options) => {
18-
loudRejection();
18+
hardRejection();
1919

2020
if (typeof helpMessage === 'object' && !Array.isArray(helpMessage)) {
2121
options = helpMessage;

‎package.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@
4040
"dependencies": {
4141
"camelcase-keys": "^4.0.0",
4242
"decamelize-keys": "^1.0.0",
43-
"loud-rejection": "^1.0.0",
43+
"hard-rejection": "^1.0.0",
4444
"minimist-options": "^3.0.1",
4545
"normalize-package-data": "^2.3.4",
4646
"read-pkg-up": "^3.0.0",

‎readme.md

+2-2
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212
- Negates flags when using the `--no-` prefix
1313
- Outputs version when `--version`
1414
- Outputs description and supplied help text when `--help`
15-
- Makes unhandled rejected promises [fail loudly](https://github.com/sindresorhus/loud-rejection) instead of the default silent fail
15+
- Makes unhandled rejected promises [fail hard](https://github.com/sindresorhus/hard-rejection) instead of the default silent fail
1616
- Sets the process title to the binary name defined in package.json
1717

1818

@@ -237,7 +237,7 @@ const cli = meow(`
237237

238238
## Promises
239239

240-
Meow will make unhandled rejected promises [fail loudly](https://github.com/sindresorhus/loud-rejection) instead of the default silent fail. Meaning you don't have to manually `.catch()` promises used in your CLI.
240+
Meow will make unhandled rejected promises [fail hard](https://github.com/sindresorhus/hard-rejection) instead of the default silent fail. Meaning you don't have to manually `.catch()` promises used in your CLI.
241241

242242

243243
## Tips

0 commit comments

Comments
 (0)
Please sign in to comment.