Add Object.isObject shim

This commit is contained in:
pyoor 2017-06-08 17:56:46 -04:00
parent 2cf47dba1d
commit d7cb85131d

View file

@ -52,3 +52,12 @@ Object.defineProperty(Array.prototype, 'map', function (fn, array) {
}) })
return result return result
}) })
Object.defineProperty(Object, 'isObject', {
configurable: true,
enumerable: false,
writable: true,
value: function (obj) {
return ((!!obj) && (obj.constructor === Object))
}
})