Do not use update in map if iteratee is a function

Performance bump, especially while curry is slow.
This commit is contained in:
Aaron Jensen 2015-08-09 23:36:34 -07:00
parent 5c64c7fbf6
commit 167760fb24

View File

@ -18,7 +18,10 @@ function clone(object) {
}
function map(iteratee, object) {
const updater = update(iteratee);
const updater = typeof iteratee === 'function' ?
iteratee :
update(iteratee);
let newObject;
forEach(object, (value, index) => {