| var assignValue = require('./_assignValue'), |
| baseAssignValue = require('./_baseAssignValue'); |
| * Copies properties of `source` to `object`. |
| * @param {Object} source The object to copy properties from. |
| * @param {Array} props The property identifiers to copy. |
| * @param {Object} [object={}] The object to copy properties to. |
| * @param {Function} [customizer] The function to customize copied values. |
| * @returns {Object} Returns `object`. |
| function copyObject(source, props, object, customizer) { |
| while (++index < length) { |
| var newValue = customizer |
| ? customizer(object[key], source[key], key, object, source) |
| if (newValue === undefined) { |
| baseAssignValue(object, key, newValue); |
| assignValue(object, key, newValue); |
| module.exports = copyObject; |