diff options
Diffstat (limited to 'node_modules/is-plain-obj/index.js')
-rw-r--r-- | node_modules/is-plain-obj/index.js | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/node_modules/is-plain-obj/index.js b/node_modules/is-plain-obj/index.js new file mode 100644 index 000000000..0d1ba9eeb --- /dev/null +++ b/node_modules/is-plain-obj/index.js @@ -0,0 +1,7 @@ +'use strict'; +var toString = Object.prototype.toString; + +module.exports = function (x) { + var prototype; + return toString.call(x) === '[object Object]' && (prototype = Object.getPrototypeOf(x), prototype === null || prototype === Object.getPrototypeOf({})); +}; |