Few grammatical corrections

Few grammatical corrections
This commit is contained in:
Venkata Pavan 2021-03-31 13:30:26 +05:30 committed by GitHub
parent 7b76185892
commit c06e21fee9
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -28,10 +28,10 @@ Its arguments `resolve` and `reject` are callbacks provided by JavaScript itself
When the executor obtains the result, be it soon or late, doesn't matter, it should call one of these callbacks:
- `resolve(value)` — if the job finished successfully, with result `value`.
- `reject(error)` — if an error occurred, `error` is the error object.
- `resolve(value)` — if the job is finished successfully, with result `value`.
- `reject(error)` — if an error has occurred, `error` is the error object.
So to summarize: the executor runs automatically and attempts to perform a job. When it is finished with the attempt it calls `resolve` if it was successful or `reject` if there was an error.
So to summarize: the executor runs automatically and attempts to perform a job. When it is finished with the attempt, it calls `resolve` if it was successful or `reject` if there was an error.
The `promise` object returned by the `new Promise` constructor has these internal properties: