wallet-core/node_modules/core-js/modules/$.object-define.js
2017-05-03 15:35:00 +02:00

11 lines
347 B
JavaScript

var $ = require('./$')
, ownKeys = require('./$.own-keys')
, toIObject = require('./$.to-iobject');
module.exports = function define(target, mixin){
var keys = ownKeys(toIObject(mixin))
, length = keys.length
, i = 0, key;
while(length > i)$.setDesc(target, key = keys[i++], $.getDesc(mixin, key));
return target;
};