_baseAssignIn.js 482 B

123456789101112131415161718
  1. var copyObject = require('./_copyObject'),
  2. keysIn = require('./keysIn');
  3. /**
  4. * The base implementation of `_.assignIn` without support for multiple sources
  5. * or `customizer` functions.
  6. *
  7. * @private
  8. * @param {Object} object The destination object.
  9. * @param {Object} source The source object.
  10. * @returns {Object} Returns `object`.
  11. */
  12. function baseAssignIn(object, source) {
  13. return object && copyObject(source, keysIn(source), object);
  14. }
  15. module.exports = baseAssignIn;