Merge pull request #2759 from KennethKinLum/patch-14

fix typo
This commit is contained in:
Ilya Kantor 2021-10-25 22:26:42 +03:00 committed by GitHub
commit 3efe4cf42a
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -303,7 +303,7 @@ The `async` keyword before a function has two effects:
The `await` keyword before a promise makes JavaScript wait until that promise settles, and then: The `await` keyword before a promise makes JavaScript wait until that promise settles, and then:
1. If it's an error, the exception is generated — same as if `throw error` were called at that very place. 1. If it's an error, an exception is generated — same as if `throw error` were called at that very place.
2. Otherwise, it returns the result. 2. Otherwise, it returns the result.
Together they provide a great framework to write asynchronous code that is easy to both read and write. Together they provide a great framework to write asynchronous code that is easy to both read and write.