Files
lodash/_addMapEntry.js
John-David Dalton 8166b65853 Bump to v4.6.0.
2016-02-29 23:38:21 -08:00

19 lines
428 B
JavaScript

define([], function() {
/**
* Adds the key-value `pair` to `map`.
*
* @private
* @param {Object} map The map to modify.
* @param {Array} pair The key-value pair to add.
* @returns {Object} Returns `map`.
*/
function addMapEntry(map, pair) {
// Don't return `Map#set` because it doesn't return the map instance in IE 11.
map.set(pair[0], pair[1]);
return map;
}
return addMapEntry;
});