diff --git a/README.md b/README.md index 49d025fb..9efbad4d 100644 --- a/README.md +++ b/README.md @@ -423,13 +423,11 @@ Other Style Guides // bad - no returned value means `acc` becomes undefined after the first iteration [[0, 1], [2, 3], [4, 5]].reduce((acc, item, index) => { const flatten = acc.concat(item); - acc[index] = flatten; }); // good [[0, 1], [2, 3], [4, 5]].reduce((acc, item, index) => { const flatten = acc.concat(item); - acc[index] = flatten; return flatten; });