diff --git a/lib/utils.js b/lib/utils.js index 368070f611..e075f9e2ab 100644 --- a/lib/utils.js +++ b/lib/utils.js @@ -132,7 +132,7 @@ const isPlainObject = (val) => { } const prototype = getPrototypeOf(val); - return prototype === null || prototype === Object.prototype; + return (prototype === null || prototype === Object.prototype || Object.getPrototypeOf(prototype) === null) && !(Symbol.toStringTag in val) && !(Symbol.iterator in val); } /**