diff --git a/maxBy.js b/maxBy.js index 9d346ebfa..5cfa987f6 100644 --- a/maxBy.js +++ b/maxBy.js @@ -22,8 +22,8 @@ function maxBy(array, iteratee) { if (array == null) { return result } + let computed for (const value of array) { - let computed const current = iteratee(value) if (current != null && (computed === undefined diff --git a/minBy.js b/minBy.js index 8f5879aeb..327428faa 100644 --- a/minBy.js +++ b/minBy.js @@ -22,8 +22,8 @@ function minBy(array, iteratee) { if (array == null) { return result } + let computed for (const value of array) { - let computed const current = iteratee(value) if (current != null && (computed === undefined