Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 1dd5e59

Browse files
committed
corrected typo
1 parent fa0387b commit 1dd5e59

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

fundamentals/promises.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -91,7 +91,7 @@ somePromise
9191

9292
> Note that `onFulfilled` and `onRejected` execute asynchronously, after the [event loop](./event_loop.md) turn in which then is called, and with a fresh stack.
9393
94-
It is also important to understand that the `.then()` method returns a new promise that resolves to the return value of `onFulfilled` (if specified) in case of the 'happy' scenario or the return value of `onRejected` (if specified) in case of an error. If the return value of these functions is a plain JavaScript value, the new promise is immediately fulfilled with that value. If the return value is yet another promise then the settlement value is of that inner promise, when settled. If the function does not return a value, the new promise is immediately fulfilled with the value `undefined`.
94+
It is also important to understand that the `.then()` method returns a new promise that resolves to the return value of `onFulfilled` (if specified) in case of the 'happy' scenario or the return value of `onRejected` (if specified) in case of an error. If the return value of these functions is a plain JavaScript value, the new promise is immediately fulfilled with that value. If the return value is yet another promise then the settlement value is that of the inner promise, when settled. If the function does not return a value, the new promise is immediately fulfilled with the value `undefined`.
9595

9696
Because `.then()` (and `.catch`) return new promises, you can chain them together such that your code can be read as: do *this*, then do *that* and then *that*, etc.:
9797

0 commit comments

Comments
 (0)