mirror of
https://github.com/musix-org/musix-oss
synced 2024-12-24 01:43:18 +00:00
15 lines
616 B
JavaScript
15 lines
616 B
JavaScript
|
var has = require('../internals/has');
|
||
|
var ownKeys = require('../internals/own-keys');
|
||
|
var getOwnPropertyDescriptorModule = require('../internals/object-get-own-property-descriptor');
|
||
|
var definePropertyModule = require('../internals/object-define-property');
|
||
|
|
||
|
module.exports = function (target, source) {
|
||
|
var keys = ownKeys(source);
|
||
|
var defineProperty = definePropertyModule.f;
|
||
|
var getOwnPropertyDescriptor = getOwnPropertyDescriptorModule.f;
|
||
|
for (var i = 0; i < keys.length; i++) {
|
||
|
var key = keys[i];
|
||
|
if (!has(target, key)) defineProperty(target, key, getOwnPropertyDescriptor(source, key));
|
||
|
}
|
||
|
};
|