We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Where Chapter 11 - Promises, under Node.js Rejection Handling
let rejected; process.on("unhandledRejection", function(reason, promise) { console.log(reason.message); // "Explosion!" console.log(rejected === promise); // true }); rejected = Promise.reject(new Error("Explosion!"));
Problem
This example creates a rejected promise with an error object and listens for the unhandledRejection event.
unhandledRejection
Reason It is not clear that the error object is the promise value
Solution
This example creates a rejected promise with an error object as its value and listens for the unhandledRejection event.
The text was updated successfully, but these errors were encountered:
No branches or pull requests
Where
Chapter 11 - Promises, under Node.js Rejection Handling
Problem
Reason
It is not clear that the error object is the promise value
Solution
The text was updated successfully, but these errors were encountered: