mirror of
https://github.com/whoisclebs/lodash.git
synced 2026-02-06 01:47:48 +00:00
Ensure shimIsPlainObject returns true for plain objects with a constructor property that has a function value.
This commit is contained in:
@@ -1948,7 +1948,8 @@
|
||||
|
||||
// avoid non Object objects, `arguments` objects, and DOM elements
|
||||
if (!(value && toString.call(value) == objectClass) ||
|
||||
(ctor = value.constructor, isFunction(ctor) && !(ctor instanceof ctor)) ||
|
||||
(!hasOwnProperty.call(value, 'constructor') &&
|
||||
(ctor = value.constructor, isFunction(ctor) && !(ctor instanceof ctor))) ||
|
||||
(!support.argsClass && isArguments(value)) ||
|
||||
(!support.nodeClass && isNode(value))) {
|
||||
return false;
|
||||
|
||||
Reference in New Issue
Block a user