From 1af33d190528aa48319cf0b86b374221e2f166cf Mon Sep 17 00:00:00 2001 From: joaquinelio Date: Sat, 19 Dec 2020 22:29:38 -0300 Subject: [PATCH] Give me five --- 1-js/11-async/05-promise-api/article.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/1-js/11-async/05-promise-api/article.md b/1-js/11-async/05-promise-api/article.md index 4ea8c0e2..e89fb52e 100644 --- a/1-js/11-async/05-promise-api/article.md +++ b/1-js/11-async/05-promise-api/article.md @@ -309,7 +309,7 @@ In practice, this method is almost never used. ## Summary -There are 5 static methods of `Promise` class: +There are 6 static methods of `Promise` class: 1. `Promise.all(promises)` -- waits for all promises to resolve and returns an array of their results. If any of the given promises rejects, it becomes the error of `Promise.all`, and all other results are ignored. 2. `Promise.allSettled(promises)` (recently added method) -- waits for all promises to settle and returns their results as an array of objects with: @@ -320,4 +320,4 @@ There are 5 static methods of `Promise` class: 5. `Promise.resolve(value)` -- makes a resolved promise with the given value. 6. `Promise.reject(error)` -- makes a rejected promise with the given error. -Of these five, `Promise.all` is probably the most common in practice. +Of all these, `Promise.all` is probably the most common in practice.