You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
14 lines
356 B
14 lines
356 B
var keys = require('./keys'); |
|
exports = function(obj, src) { |
|
var _keys = keys(src); |
|
var len = _keys.length; |
|
if (obj == null) return !len; |
|
obj = Object(obj); |
|
for (var i = 0; i < len; i++) { |
|
var key = _keys[i]; |
|
if (src[key] !== obj[key] || !(key in obj)) return false; |
|
} |
|
return true; |
|
}; |
|
|
|
module.exports = exports;
|
|
|