We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 80c44be commit e7c1c7eCopy full SHA for e7c1c7e
src/utils/isPlainObject.ts
@@ -3,7 +3,7 @@
3
* @returns True if the argument appears to be a plain object.
4
*/
5
export default function isPlainObject(obj: any): boolean {
6
- if (!obj) return false
+ if (typeof obj !== 'object' || obj === null) return false
7
8
const proto = obj.__proto__
9
return !proto || !Object.getPrototypeOf(proto)
0 commit comments