mirror of
https://github.com/whoisclebs/lodash.git
synced 2026-02-08 10:17:48 +00:00
Apply even more let/const transforms.
This commit is contained in:
@@ -42,8 +42,8 @@ import isArray from './isArray.js';
|
||||
* // => { '1': ['a', 'c'], '2': ['b'] } (iteration order is not guaranteed)
|
||||
*/
|
||||
function reduce(collection, iteratee, accumulator) {
|
||||
var func = isArray(collection) ? arrayReduce : baseReduce,
|
||||
initAccum = arguments.length < 3;
|
||||
const func = isArray(collection) ? arrayReduce : baseReduce;
|
||||
const initAccum = arguments.length < 3;
|
||||
|
||||
return func(collection, baseIteratee(iteratee, 4), accumulator, initAccum, baseEach);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user