Skip to content

Commit 5a50ef4

Browse files
authored
docs(array-foreach): fix code example using redundant async/await
1 parent da0a19a commit 5a50ef4

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

docs/rules/array-foreach.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -85,7 +85,7 @@ If `polishApple` need to do some async work, then we'd need to refactor the iter
8585
```diff
8686
- apples.forEach(polishApple)
8787
+ await Promise.all(
88-
+ apples.map(async apple => await polishApple(apple))
88+
+ apples.map(polishApple)
8989
+ )
9090
```
9191

0 commit comments

Comments
 (0)