Bump to v3.3.0.

This commit is contained in:
John-David Dalton
2015-12-16 17:46:57 -08:00
parent 3ccb5e7da3
commit f8e4370129
91 changed files with 826 additions and 401 deletions

View File

@@ -20,16 +20,14 @@ define(['../internal/isIterateeCall', './keys'], function(isIterateeCall, keys)
* @returns {Object} Returns the new inverted object.
* @example
*
* _.invert({ 'first': 'fred', 'second': 'barney' });
* // => { 'fred': 'first', 'barney': 'second' }
* var object = { 'a': 1, 'b': 2, 'c': 1 };
*
* // without `multiValue`
* _.invert({ 'first': 'fred', 'second': 'barney', 'third': 'fred' });
* // => { 'fred': 'third', 'barney': 'second' }
* _.invert(object);
* // => { '1': 'c', '2': 'b' }
*
* // with `multiValue`
* _.invert({ 'first': 'fred', 'second': 'barney', 'third': 'fred' }, true);
* // => { 'fred': ['first', 'third'], 'barney': ['second'] }
* _.invert(object, true);
* // => { '1': ['a', 'c'], '2': ['b'] }
*/
function invert(object, multiValue, guard) {
if (guard && isIterateeCall(object, multiValue, guard)) {