Remove baseIteratee and castFunction.

This commit is contained in:
John-David Dalton
2017-01-09 17:17:03 -08:00
parent efcf51c7bf
commit 65654f8f9e
96 changed files with 140 additions and 537 deletions

View File

@@ -1,5 +1,4 @@
import baseFor from './_baseFor.js';
import castFunction from './_castFunction.js';
import keysIn from './keysIn.js';
/**
@@ -13,7 +12,7 @@ import keysIn from './keysIn.js';
* @since 0.3.0
* @category Object
* @param {Object} object The object to iterate over.
* @param {Function} [iteratee=_.identity] The function invoked per iteration.
* @param {Function} iteratee The function invoked per iteration.
* @returns {Object} Returns `object`.
* @see _.forInRight
* @example
@@ -31,9 +30,7 @@ import keysIn from './keysIn.js';
* // => Logs 'a', 'b', then 'c' (iteration order is not guaranteed).
*/
function forIn(object, iteratee) {
return object == null
? object
: baseFor(object, castFunction(iteratee), keysIn);
return object == null ? object : baseFor(object, iteratee, keysIn);
}
export default forIn;