Merge pull request #3060 from smith558/patch-4

Fix grammar and phrasing
This commit is contained in:
Ilya Kantor 2022-06-18 22:07:25 +03:00 committed by GitHub
commit 964c7db81a
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -237,7 +237,7 @@ new Promise((resolve, reject) => {
That said, `finally(f)` isn't exactly an alias of `then(f,f)` though. There are few subtle differences:
1. A `finally` handler has no arguments. In `finally` we don't know whether the promise is successful or not. That's all right, as our task is usually to perform "general" finalizing procedures.
2. A `finally` handler passes through results and errors to the next handler.
2. A `finally` handler "passes through" the result or error to the next handler.
For instance, here the result is passed through `finally` to `then`:
```js run