From 73429e7779a47aa1367b9a28d322b4770ed0d895 Mon Sep 17 00:00:00 2001 From: John-David Dalton Date: Fri, 20 Jun 2014 11:59:40 -0700 Subject: [PATCH] Remove `_.isObject` use from `_.omit` and `_.pick`. --- lodash.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lodash.js b/lodash.js index 3dba362af..aaba249b3 100644 --- a/lodash.js +++ b/lodash.js @@ -7176,7 +7176,7 @@ * // => { 'name': 'fred' } */ function omit(object, predicate, thisArg) { - if (!isObject(object)) { + if (object == null) { return {}; } if (typeof predicate == 'function') { @@ -7241,7 +7241,7 @@ * // => { 'name': 'fred' } */ function pick(object, predicate, thisArg) { - if (!isObject(object)) { + if (object == null) { return {}; } return basePick(object, typeof predicate == 'function'