From a9140d2c8f2ed7ed07eb43474a0ffe287d847d6d Mon Sep 17 00:00:00 2001 From: John-David Dalton Date: Sun, 24 Jan 2016 22:41:24 -0800 Subject: [PATCH] Bump to v4.0.2. --- README.md | 2 +- lodash._baseeach/LICENSE | 33 ++--- lodash._baseeach/README.md | 4 +- lodash._baseeach/index.js | 6 +- lodash._baseeach/package.json | 2 +- lodash._baseeachright/LICENSE | 33 ++--- lodash._baseeachright/README.md | 4 +- lodash._baseeachright/index.js | 6 +- lodash._baseeachright/package.json | 2 +- lodash._basefilter/LICENSE | 23 --- lodash._basefilter/README.md | 18 --- lodash._basefilter/index.js | 29 ---- lodash._basefilter/package.json | 19 --- lodash._baseisequal/README.md | 4 +- lodash._baseisequal/index.js | 16 +-- lodash._baseisequal/package.json | 2 +- lodash._baseismatch/README.md | 4 +- lodash._baseismatch/index.js | 7 +- lodash._baseismatch/package.json | 2 +- lodash._basepullat/README.md | 4 +- lodash._basepullat/index.js | 51 ++++++- lodash._basepullat/package.json | 2 +- lodash._baseset/README.md | 4 +- lodash._baseset/index.js | 49 ++++++- lodash._baseset/package.json | 2 +- lodash._basesortedindexby/LICENSE | 47 ------- lodash._basesortedindexby/README.md | 18 --- lodash._basesortedindexby/index.js | 135 ------------------ lodash._basesortedindexby/package.json | 16 --- lodash._basesorteduniqby/LICENSE | 23 --- lodash._basesorteduniqby/README.md | 18 --- lodash._basesorteduniqby/index.js | 76 ---------- lodash._basesorteduniqby/package.json | 16 --- lodash._createset/LICENSE | 60 +++++--- lodash._createset/README.md | 4 +- lodash._createset/index.js | 77 +++++----- lodash._createset/package.json | 2 +- lodash._createwrapper/README.md | 4 +- lodash._createwrapper/index.js | 22 +-- lodash._createwrapper/package.json | 4 +- lodash._setcache/LICENSE | 33 ++--- lodash._setcache/README.md | 4 +- lodash._setcache/index.js | 5 +- lodash._setcache/package.json | 2 +- lodash._stack/README.md | 4 +- lodash._stack/index.js | 5 +- lodash._stack/package.json | 2 +- lodash.after/LICENSE | 29 +++- lodash.after/README.md | 4 +- lodash.after/index.js | 93 +++++++++++-- lodash.after/package.json | 4 +- lodash.assign/README.md | 4 +- lodash.assign/index.js | 6 +- lodash.assign/package.json | 4 +- lodash.assignin/README.md | 4 +- lodash.assignin/index.js | 6 +- lodash.assignin/package.json | 4 +- lodash.assigninwith/README.md | 4 +- lodash.assigninwith/index.js | 6 +- lodash.assigninwith/package.json | 4 +- lodash.assignwith/README.md | 4 +- lodash.assignwith/index.js | 6 +- lodash.assignwith/package.json | 4 +- lodash.before/LICENSE | 29 +++- lodash.before/README.md | 4 +- lodash.before/index.js | 91 ++++++++++-- lodash.before/package.json | 4 +- lodash.capitalize/README.md | 4 +- lodash.capitalize/index.js | 10 +- lodash.capitalize/package.json | 2 +- lodash.ceil/README.md | 4 +- lodash.ceil/index.js | 63 ++++++--- lodash.ceil/package.json | 2 +- lodash.chunk/LICENSE | 33 ++--- lodash.chunk/README.md | 4 +- lodash.chunk/index.js | 10 +- lodash.chunk/package.json | 4 +- lodash.clamp/LICENSE | 29 +++- lodash.clamp/README.md | 4 +- lodash.clamp/index.js | 91 ++++++++++-- lodash.clamp/package.json | 4 +- lodash.clone/README.md | 4 +- lodash.clone/index.js | 16 +-- lodash.clone/package.json | 2 +- lodash.clonedeep/README.md | 4 +- lodash.clonedeep/index.js | 16 +-- lodash.clonedeep/package.json | 2 +- lodash.clonedeepwith/README.md | 4 +- lodash.clonedeepwith/index.js | 18 +-- lodash.clonedeepwith/package.json | 2 +- lodash.clonewith/README.md | 4 +- lodash.clonewith/index.js | 20 +-- lodash.clonewith/package.json | 2 +- lodash.cond/README.md | 4 +- lodash.cond/index.js | 53 ++++++- lodash.cond/package.json | 4 +- lodash.conforms/README.md | 4 +- lodash.conforms/index.js | 16 +-- lodash.conforms/package.json | 2 +- lodash.countby/README.md | 4 +- lodash.countby/index.js | 66 ++++++--- lodash.countby/package.json | 4 +- lodash.create/LICENSE | 33 ++--- lodash.create/README.md | 4 +- lodash.create/index.js | 26 ++-- lodash.create/package.json | 2 +- lodash.debounce/LICENSE | 33 ++--- lodash.debounce/README.md | 4 +- lodash.debounce/index.js | 4 +- lodash.debounce/package.json | 2 +- lodash.defaultsdeep/README.md | 4 +- lodash.defaultsdeep/index.js | 56 +++++--- lodash.defaultsdeep/package.json | 2 +- lodash.delay/LICENSE | 29 +++- lodash.delay/README.md | 4 +- lodash.delay/index.js | 93 +++++++++++-- lodash.delay/package.json | 4 +- lodash.difference/README.md | 4 +- lodash.difference/index.js | 6 +- lodash.difference/package.json | 4 +- lodash.differenceby/README.md | 4 +- lodash.differenceby/index.js | 12 +- lodash.differenceby/package.json | 2 +- lodash.differencewith/README.md | 4 +- lodash.differencewith/index.js | 4 +- lodash.differencewith/package.json | 4 +- lodash.drop/LICENSE | 33 ++--- lodash.drop/README.md | 4 +- lodash.drop/index.js | 2 +- lodash.drop/package.json | 6 +- lodash.dropright/LICENSE | 33 ++--- lodash.dropright/README.md | 4 +- lodash.dropright/index.js | 2 +- lodash.dropright/package.json | 6 +- lodash.droprightwhile/README.md | 4 +- lodash.droprightwhile/index.js | 55 +++++++- lodash.droprightwhile/package.json | 4 +- lodash.dropwhile/README.md | 4 +- lodash.dropwhile/index.js | 55 +++++++- lodash.dropwhile/package.json | 4 +- lodash.escaperegexp/README.md | 4 +- lodash.escaperegexp/index.js | 49 ++++++- lodash.escaperegexp/package.json | 4 +- lodash.every/README.md | 4 +- lodash.every/index.js | 55 +++++++- lodash.every/package.json | 4 +- lodash.filter/README.md | 4 +- lodash.filter/index.js | 55 +++++++- lodash.filter/package.json | 4 +- lodash.find/README.md | 4 +- lodash.find/index.js | 55 +++++++- lodash.find/package.json | 4 +- lodash.findindex/README.md | 4 +- lodash.findindex/index.js | 55 +++++++- lodash.findindex/package.json | 4 +- lodash.findkey/README.md | 4 +- lodash.findkey/index.js | 55 +++++++- lodash.findkey/package.json | 4 +- lodash.findlast/README.md | 4 +- lodash.findlast/index.js | 49 ++++++- lodash.findlast/package.json | 4 +- lodash.findlastindex/README.md | 4 +- lodash.findlastindex/index.js | 55 +++++++- lodash.findlastindex/package.json | 4 +- lodash.findlastkey/README.md | 4 +- lodash.findlastkey/index.js | 55 +++++++- lodash.findlastkey/package.json | 4 +- lodash.floor/README.md | 4 +- lodash.floor/index.js | 63 ++++++--- lodash.floor/package.json | 2 +- lodash.foreachright/README.md | 4 +- lodash.foreachright/index.js | 2 +- lodash.foreachright/package.json | 6 +- lodash.forin/README.md | 4 +- lodash.forin/index.js | 2 +- lodash.forin/package.json | 6 +- lodash.forown/README.md | 4 +- lodash.forown/index.js | 2 +- lodash.forown/package.json | 6 +- lodash.get/README.md | 4 +- lodash.get/index.js | 49 ++++++- lodash.get/package.json | 4 +- lodash.groupby/README.md | 4 +- lodash.groupby/index.js | 66 ++++++--- lodash.groupby/package.json | 4 +- lodash.has/README.md | 4 +- lodash.has/index.js | 11 +- lodash.has/package.json | 4 +- lodash.hasin/README.md | 4 +- lodash.hasin/index.js | 11 +- lodash.hasin/package.json | 4 +- lodash.indexof/LICENSE | 29 +++- lodash.indexof/README.md | 4 +- lodash.indexof/index.js | 95 +++++++++++-- lodash.indexof/package.json | 4 +- lodash.initial/LICENSE | 33 ++--- lodash.initial/README.md | 4 +- lodash.initial/index.js | 2 +- lodash.initial/package.json | 6 +- lodash.intersection/README.md | 4 +- lodash.intersection/index.js | 8 +- lodash.intersection/package.json | 4 +- lodash.intersectionby/README.md | 4 +- lodash.intersectionby/index.js | 12 +- lodash.intersectionby/package.json | 2 +- lodash.intersectionwith/README.md | 4 +- lodash.intersectionwith/index.js | 4 +- lodash.intersectionwith/package.json | 4 +- lodash.invoke/README.md | 4 +- lodash.invoke/index.js | 53 ++++++- lodash.invoke/package.json | 4 +- lodash.invokemap/README.md | 4 +- lodash.invokemap/index.js | 53 ++++++- lodash.invokemap/package.json | 4 +- lodash.isarraylike/LICENSE | 33 ++--- lodash.isarraylike/README.md | 4 +- lodash.isarraylike/index.js | 6 +- lodash.isarraylike/package.json | 2 +- lodash.isarraylikeobject/LICENSE | 33 ++--- lodash.isarraylikeobject/README.md | 4 +- lodash.isarraylikeobject/index.js | 7 +- lodash.isarraylikeobject/package.json | 2 +- lodash.isinteger/LICENSE | 29 +++- lodash.isinteger/README.md | 4 +- lodash.isinteger/index.js | 94 +++++++++++-- lodash.isinteger/package.json | 4 +- lodash.isplainobject/LICENSE | 33 ++--- lodash.isplainobject/README.md | 4 +- lodash.isplainobject/index.js | 5 +- lodash.isplainobject/package.json | 2 +- lodash.issafeinteger/LICENSE | 29 +++- lodash.issafeinteger/README.md | 4 +- lodash.issafeinteger/index.js | 107 +++++++++++--- lodash.issafeinteger/package.json | 4 +- lodash.iteratee/README.md | 4 +- lodash.iteratee/index.js | 20 +-- lodash.iteratee/package.json | 2 +- lodash.keyby/README.md | 4 +- lodash.keyby/index.js | 72 ++++++---- lodash.keyby/package.json | 4 +- lodash.keys/README.md | 4 +- lodash.keys/index.js | 4 +- lodash.keys/package.json | 2 +- lodash.keysin/README.md | 4 +- lodash.keysin/index.js | 49 ++++++- lodash.keysin/package.json | 2 +- lodash.lastindexof/LICENSE | 29 +++- lodash.lastindexof/README.md | 4 +- lodash.lastindexof/index.js | 97 +++++++++++-- lodash.lastindexof/package.json | 4 +- lodash.lowerfirst/README.md | 4 +- lodash.lowerfirst/index.js | 49 ++++++- lodash.lowerfirst/package.json | 4 +- lodash.map/README.md | 4 +- lodash.map/index.js | 51 ++++++- lodash.map/package.json | 4 +- lodash.mapkeys/README.md | 4 +- lodash.mapkeys/index.js | 49 ++++++- lodash.mapkeys/package.json | 4 +- lodash.mapvalues/README.md | 4 +- lodash.mapvalues/index.js | 51 ++++++- lodash.mapvalues/package.json | 4 +- lodash.matches/README.md | 4 +- lodash.matches/index.js | 16 +-- lodash.matches/package.json | 2 +- lodash.matchesproperty/README.md | 4 +- lodash.matchesproperty/index.js | 16 +-- lodash.matchesproperty/package.json | 2 +- lodash.maxby/README.md | 4 +- lodash.maxby/index.js | 51 ++++++- lodash.maxby/package.json | 4 +- lodash.memoize/LICENSE | 33 ++--- lodash.memoize/README.md | 4 +- lodash.memoize/index.js | 2 +- lodash.memoize/package.json | 8 +- lodash.merge/README.md | 4 +- lodash.merge/index.js | 58 +++++--- lodash.merge/package.json | 2 +- lodash.mergewith/README.md | 4 +- lodash.mergewith/index.js | 58 +++++--- lodash.mergewith/package.json | 2 +- lodash.method/README.md | 4 +- lodash.method/index.js | 53 ++++++- lodash.method/package.json | 4 +- lodash.methodof/README.md | 4 +- lodash.methodof/index.js | 53 ++++++- lodash.methodof/package.json | 4 +- lodash.minby/README.md | 4 +- lodash.minby/index.js | 51 ++++++- lodash.minby/package.json | 4 +- lodash.now/README.md | 4 +- lodash.now/index.js | 15 +- lodash.now/package.json | 2 +- lodash.ntharg/LICENSE | 29 +++- lodash.ntharg/README.md | 4 +- lodash.ntharg/index.js | 91 ++++++++++-- lodash.ntharg/package.json | 4 +- lodash.omit/README.md | 4 +- lodash.omit/index.js | 8 +- lodash.omit/package.json | 2 +- lodash.omitby/README.md | 4 +- lodash.omitby/index.js | 49 ++++++- lodash.omitby/package.json | 4 +- lodash.orderby/README.md | 4 +- lodash.orderby/index.js | 51 ++++++- lodash.orderby/package.json | 4 +- lodash.over/README.md | 4 +- lodash.over/index.js | 53 ++++++- lodash.over/package.json | 4 +- lodash.overargs/README.md | 4 +- lodash.overargs/index.js | 53 ++++++- lodash.overargs/package.json | 4 +- lodash.overevery/README.md | 4 +- lodash.overevery/index.js | 53 ++++++- lodash.overevery/package.json | 4 +- lodash.oversome/README.md | 4 +- lodash.oversome/index.js | 53 ++++++- lodash.oversome/package.json | 4 +- lodash.padend/README.md | 4 +- lodash.padend/index.js | 51 ++++++- lodash.padend/package.json | 4 +- lodash.padstart/README.md | 4 +- lodash.padstart/index.js | 51 ++++++- lodash.padstart/package.json | 4 +- lodash.parseint/LICENSE | 60 +++++--- lodash.parseint/README.md | 4 +- lodash.parseint/index.js | 137 +++++++++++++++++- lodash.parseint/package.json | 8 +- lodash.partition/README.md | 4 +- lodash.partition/index.js | 66 ++++++--- lodash.partition/package.json | 4 +- lodash.pickby/README.md | 4 +- lodash.pickby/index.js | 51 ++++++- lodash.pickby/package.json | 4 +- lodash.property/README.md | 4 +- lodash.property/index.js | 49 ++++++- lodash.property/package.json | 4 +- lodash.propertyof/README.md | 4 +- lodash.propertyof/index.js | 49 ++++++- lodash.propertyof/package.json | 4 +- lodash.pullallby/README.md | 4 +- lodash.pullallby/index.js | 12 +- lodash.pullallby/package.json | 2 +- lodash.rangeright/LICENSE | 33 ++--- lodash.rangeright/README.md | 4 +- lodash.rangeright/index.js | 6 +- lodash.rangeright/package.json | 2 +- lodash.reduce/README.md | 4 +- lodash.reduce/index.js | 49 ++++++- lodash.reduce/package.json | 4 +- lodash.reduceright/README.md | 4 +- lodash.reduceright/index.js | 49 ++++++- lodash.reduceright/package.json | 4 +- lodash.reject/README.md | 4 +- lodash.reject/index.js | 55 +++++++- lodash.reject/package.json | 4 +- lodash.remove/README.md | 4 +- lodash.remove/index.js | 49 ++++++- lodash.remove/package.json | 4 +- lodash.repeat/README.md | 4 +- lodash.repeat/index.js | 186 ++++++++++++++++++++++++- lodash.repeat/package.json | 2 +- lodash.replace/README.md | 4 +- lodash.replace/index.js | 49 ++++++- lodash.replace/package.json | 4 +- lodash.rest/LICENSE | 29 +++- lodash.rest/README.md | 4 +- lodash.rest/index.js | 99 +++++++++++-- lodash.rest/package.json | 4 +- lodash.result/README.md | 4 +- lodash.result/index.js | 49 ++++++- lodash.result/package.json | 4 +- lodash.round/README.md | 4 +- lodash.round/index.js | 63 ++++++--- lodash.round/package.json | 2 +- lodash.samplesize/LICENSE | 29 +++- lodash.samplesize/README.md | 4 +- lodash.samplesize/index.js | 83 +++++++++-- lodash.samplesize/package.json | 4 +- lodash.size/README.md | 4 +- lodash.size/index.js | 4 +- lodash.size/package.json | 4 +- lodash.slice/LICENSE | 33 ++--- lodash.slice/README.md | 4 +- lodash.slice/index.js | 6 +- lodash.slice/package.json | 2 +- lodash.some/README.md | 4 +- lodash.some/index.js | 55 +++++++- lodash.some/package.json | 4 +- lodash.sortby/README.md | 4 +- lodash.sortby/index.js | 49 ++++++- lodash.sortby/package.json | 4 +- lodash.sortedindex/LICENSE | 33 ++--- lodash.sortedindex/README.md | 4 +- lodash.sortedindex/index.js | 11 +- lodash.sortedindex/package.json | 8 +- lodash.sortedindexby/README.md | 4 +- lodash.sortedindexby/index.js | 12 +- lodash.sortedindexby/package.json | 2 +- lodash.sortedindexof/LICENSE | 33 ++--- lodash.sortedindexof/README.md | 4 +- lodash.sortedindexof/index.js | 8 +- lodash.sortedindexof/package.json | 8 +- lodash.sortedlastindex/LICENSE | 33 ++--- lodash.sortedlastindex/README.md | 4 +- lodash.sortedlastindex/index.js | 7 +- lodash.sortedlastindex/package.json | 8 +- lodash.sortedlastindexby/README.md | 4 +- lodash.sortedlastindexby/index.js | 12 +- lodash.sortedlastindexby/package.json | 2 +- lodash.sortedlastindexof/LICENSE | 33 ++--- lodash.sortedlastindexof/README.md | 4 +- lodash.sortedlastindexof/index.js | 8 +- lodash.sortedlastindexof/package.json | 8 +- lodash.sorteduniq/LICENSE | 33 ++--- lodash.sorteduniq/README.md | 4 +- lodash.sorteduniq/index.js | 3 +- lodash.sorteduniq/package.json | 8 +- lodash.sorteduniqby/README.md | 4 +- lodash.sorteduniqby/index.js | 12 +- lodash.sorteduniqby/package.json | 2 +- lodash.split/README.md | 4 +- lodash.split/index.js | 49 ++++++- lodash.split/package.json | 4 +- lodash.subtract/LICENSE | 60 +++++--- lodash.subtract/README.md | 4 +- lodash.subtract/index.js | 48 ++++--- lodash.subtract/package.json | 4 +- lodash.sum/README.md | 4 +- lodash.sum/index.js | 15 +- lodash.sum/package.json | 2 +- lodash.sumby/README.md | 4 +- lodash.sumby/index.js | 8 +- lodash.sumby/package.json | 4 +- lodash.tail/LICENSE | 33 ++--- lodash.tail/README.md | 4 +- lodash.tail/index.js | 2 +- lodash.tail/package.json | 6 +- lodash.take/LICENSE | 33 ++--- lodash.take/README.md | 4 +- lodash.take/index.js | 2 +- lodash.take/package.json | 6 +- lodash.takeright/LICENSE | 33 ++--- lodash.takeright/README.md | 4 +- lodash.takeright/index.js | 2 +- lodash.takeright/package.json | 6 +- lodash.takerightwhile/README.md | 4 +- lodash.takerightwhile/index.js | 55 +++++++- lodash.takerightwhile/package.json | 4 +- lodash.takewhile/README.md | 4 +- lodash.takewhile/index.js | 55 +++++++- lodash.takewhile/package.json | 4 +- lodash.template/README.md | 4 +- lodash.template/index.js | 81 ++++++++--- lodash.template/package.json | 4 +- lodash.times/LICENSE | 33 ++--- lodash.times/README.md | 4 +- lodash.times/index.js | 20 +-- lodash.times/package.json | 2 +- lodash.toarray/README.md | 4 +- lodash.toarray/index.js | 55 +++++++- lodash.toarray/package.json | 4 +- lodash.tointeger/LICENSE | 29 +++- lodash.tointeger/README.md | 4 +- lodash.tointeger/index.js | 90 ++++++++++-- lodash.tointeger/package.json | 4 +- lodash.tolength/LICENSE | 29 +++- lodash.tolength/README.md | 4 +- lodash.tolength/index.js | 94 +++++++++++-- lodash.tolength/package.json | 4 +- lodash.tolower/README.md | 4 +- lodash.tolower/index.js | 49 ++++++- lodash.tolower/package.json | 4 +- lodash.tonumber/LICENSE | 29 +++- lodash.tonumber/README.md | 4 +- lodash.tonumber/index.js | 88 ++++++++++-- lodash.tonumber/package.json | 4 +- lodash.topath/README.md | 4 +- lodash.topath/index.js | 49 ++++++- lodash.topath/package.json | 4 +- lodash.toplainobject/LICENSE | 33 ++--- lodash.toplainobject/README.md | 4 +- lodash.toplainobject/index.js | 9 +- lodash.toplainobject/package.json | 2 +- lodash.tosafeinteger/LICENSE | 29 +++- lodash.tosafeinteger/README.md | 4 +- lodash.tosafeinteger/index.js | 91 ++++++++++-- lodash.tosafeinteger/package.json | 4 +- lodash.tostring/README.md | 4 +- lodash.tostring/index.js | 49 ++++++- lodash.tostring/package.json | 4 +- lodash.toupper/README.md | 4 +- lodash.toupper/index.js | 49 ++++++- lodash.toupper/package.json | 4 +- lodash.transform/README.md | 4 +- lodash.transform/index.js | 49 ++++++- lodash.transform/package.json | 4 +- lodash.trim/README.md | 4 +- lodash.trim/index.js | 49 ++++++- lodash.trim/package.json | 4 +- lodash.trimend/README.md | 4 +- lodash.trimend/index.js | 20 +-- lodash.trimend/package.json | 2 +- lodash.trimstart/README.md | 4 +- lodash.trimstart/index.js | 20 +-- lodash.trimstart/package.json | 2 +- lodash.truncate/README.md | 4 +- lodash.truncate/index.js | 51 ++++++- lodash.truncate/package.json | 4 +- lodash.union/README.md | 4 +- lodash.union/index.js | 51 ++++++- lodash.union/package.json | 4 +- lodash.unionby/README.md | 4 +- lodash.unionby/index.js | 12 +- lodash.unionby/package.json | 2 +- lodash.unionwith/README.md | 4 +- lodash.unionwith/index.js | 51 ++++++- lodash.unionwith/package.json | 4 +- lodash.uniq/README.md | 4 +- lodash.uniq/index.js | 51 ++++++- lodash.uniq/package.json | 4 +- lodash.uniqby/README.md | 4 +- lodash.uniqby/index.js | 12 +- lodash.uniqby/package.json | 2 +- lodash.uniqwith/README.md | 4 +- lodash.uniqwith/index.js | 51 ++++++- lodash.uniqwith/package.json | 4 +- lodash.unset/README.md | 4 +- lodash.unset/index.js | 51 ++++++- lodash.unset/package.json | 4 +- lodash.upperfirst/README.md | 4 +- lodash.upperfirst/index.js | 49 ++++++- lodash.upperfirst/package.json | 4 +- lodash.without/README.md | 4 +- lodash.without/index.js | 6 +- lodash.without/package.json | 4 +- lodash.xor/README.md | 4 +- lodash.xor/index.js | 51 ++++++- lodash.xor/package.json | 4 +- lodash.xorby/README.md | 4 +- lodash.xorby/index.js | 12 +- lodash.xorby/package.json | 2 +- lodash.xorwith/README.md | 4 +- lodash.xorwith/index.js | 51 ++++++- lodash.xorwith/package.json | 4 +- 545 files changed, 6999 insertions(+), 2625 deletions(-) delete mode 100644 lodash._basefilter/LICENSE delete mode 100644 lodash._basefilter/README.md delete mode 100644 lodash._basefilter/index.js delete mode 100644 lodash._basefilter/package.json delete mode 100644 lodash._basesortedindexby/LICENSE delete mode 100644 lodash._basesortedindexby/README.md delete mode 100644 lodash._basesortedindexby/index.js delete mode 100644 lodash._basesortedindexby/package.json delete mode 100644 lodash._basesorteduniqby/LICENSE delete mode 100644 lodash._basesorteduniqby/README.md delete mode 100644 lodash._basesorteduniqby/index.js delete mode 100644 lodash._basesorteduniqby/package.json diff --git a/README.md b/README.md index 600ef1348..9eeb4fbfb 100644 --- a/README.md +++ b/README.md @@ -1,4 +1,4 @@ -# lodash v4.0.1 +# lodash v4.0.2 The [lodash](https://lodash.com/) library exported as [npm packages](https://www.npmjs.com/browse/keyword/lodash-modularized) per method. diff --git a/lodash._baseeach/LICENSE b/lodash._baseeach/LICENSE index b054ca5a3..bcbe13d67 100644 --- a/lodash._baseeach/LICENSE +++ b/lodash._baseeach/LICENSE @@ -1,22 +1,23 @@ +The MIT License (MIT) + Copyright 2012-2016 The Dojo Foundation Based on Underscore.js, copyright 2009-2016 Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors -Permission is hereby granted, free of charge, to any person obtaining -a copy of this software and associated documentation files (the -"Software"), to deal in the Software without restriction, including -without limitation the rights to use, copy, modify, merge, publish, -distribute, sublicense, and/or sell copies of the Software, and to -permit persons to whom the Software is furnished to do so, subject to -the following conditions: +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: -The above copyright notice and this permission notice shall be -included in all copies or substantial portions of the Software. +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, -EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND -NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE -LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION -OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION -WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. diff --git a/lodash._baseeach/README.md b/lodash._baseeach/README.md index 1071bd55d..3a5b585f3 100644 --- a/lodash._baseeach/README.md +++ b/lodash._baseeach/README.md @@ -1,4 +1,4 @@ -# lodash._baseeach v4.0.1 +# lodash._baseeach v4.0.2 The internal [lodash](https://lodash.com/) function `baseEach` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var baseEach = require('lodash._baseeach'); ``` -See the [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash._baseeach) for more details. +See the [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash._baseeach) for more details. diff --git a/lodash._baseeach/index.js b/lodash._baseeach/index.js index 473a38c7a..f63c1de76 100644 --- a/lodash._baseeach/index.js +++ b/lodash._baseeach/index.js @@ -1,5 +1,5 @@ /** - * lodash 4.0.1 (Custom Build) + * lodash 4.0.2 (Custom Build) * Build: `lodash modularize exports="npm" -o ./` * Copyright 2012-2016 The Dojo Foundation * Based on Underscore.js 1.8.3 @@ -145,7 +145,6 @@ var getLength = baseProperty('length'); * * @static * @memberOf _ - * @type Function * @category Lang * @param {*} value The value to check. * @returns {boolean} Returns `true` if `value` is array-like, else `false`. @@ -217,7 +216,8 @@ function isFunction(value) { * // => false */ function isLength(value) { - return typeof value == 'number' && value > -1 && value % 1 == 0 && value <= MAX_SAFE_INTEGER; + return typeof value == 'number' && + value > -1 && value % 1 == 0 && value <= MAX_SAFE_INTEGER; } /** diff --git a/lodash._baseeach/package.json b/lodash._baseeach/package.json index 0189cf9a8..f827025ec 100644 --- a/lodash._baseeach/package.json +++ b/lodash._baseeach/package.json @@ -1,6 +1,6 @@ { "name": "lodash._baseeach", - "version": "4.0.1", + "version": "4.0.2", "description": "The internal lodash function `baseEach` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", diff --git a/lodash._baseeachright/LICENSE b/lodash._baseeachright/LICENSE index b054ca5a3..bcbe13d67 100644 --- a/lodash._baseeachright/LICENSE +++ b/lodash._baseeachright/LICENSE @@ -1,22 +1,23 @@ +The MIT License (MIT) + Copyright 2012-2016 The Dojo Foundation Based on Underscore.js, copyright 2009-2016 Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors -Permission is hereby granted, free of charge, to any person obtaining -a copy of this software and associated documentation files (the -"Software"), to deal in the Software without restriction, including -without limitation the rights to use, copy, modify, merge, publish, -distribute, sublicense, and/or sell copies of the Software, and to -permit persons to whom the Software is furnished to do so, subject to -the following conditions: +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: -The above copyright notice and this permission notice shall be -included in all copies or substantial portions of the Software. +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, -EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND -NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE -LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION -OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION -WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. diff --git a/lodash._baseeachright/README.md b/lodash._baseeachright/README.md index 8525722b8..af27dd3a9 100644 --- a/lodash._baseeachright/README.md +++ b/lodash._baseeachright/README.md @@ -1,4 +1,4 @@ -# lodash._baseeachright v4.0.1 +# lodash._baseeachright v4.0.2 The internal [lodash](https://lodash.com/) function `baseEachRight` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var baseEachRight = require('lodash._baseeachright'); ``` -See the [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash._baseeachright) for more details. +See the [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash._baseeachright) for more details. diff --git a/lodash._baseeachright/index.js b/lodash._baseeachright/index.js index 31b4cf09c..3ff433243 100644 --- a/lodash._baseeachright/index.js +++ b/lodash._baseeachright/index.js @@ -1,5 +1,5 @@ /** - * lodash 4.0.1 (Custom Build) + * lodash 4.0.2 (Custom Build) * Build: `lodash modularize exports="npm" -o ./` * Copyright 2012-2016 The Dojo Foundation * Based on Underscore.js 1.8.3 @@ -143,7 +143,6 @@ var getLength = baseProperty('length'); * * @static * @memberOf _ - * @type Function * @category Lang * @param {*} value The value to check. * @returns {boolean} Returns `true` if `value` is array-like, else `false`. @@ -215,7 +214,8 @@ function isFunction(value) { * // => false */ function isLength(value) { - return typeof value == 'number' && value > -1 && value % 1 == 0 && value <= MAX_SAFE_INTEGER; + return typeof value == 'number' && + value > -1 && value % 1 == 0 && value <= MAX_SAFE_INTEGER; } /** diff --git a/lodash._baseeachright/package.json b/lodash._baseeachright/package.json index a5c97357c..5ace8a194 100644 --- a/lodash._baseeachright/package.json +++ b/lodash._baseeachright/package.json @@ -1,6 +1,6 @@ { "name": "lodash._baseeachright", - "version": "4.0.1", + "version": "4.0.2", "description": "The internal lodash function `baseEachRight` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", diff --git a/lodash._basefilter/LICENSE b/lodash._basefilter/LICENSE deleted file mode 100644 index bcbe13d67..000000000 --- a/lodash._basefilter/LICENSE +++ /dev/null @@ -1,23 +0,0 @@ -The MIT License (MIT) - -Copyright 2012-2016 The Dojo Foundation -Based on Underscore.js, copyright 2009-2016 Jeremy Ashkenas, -DocumentCloud and Investigative Reporters & Editors - -Permission is hereby granted, free of charge, to any person obtaining a copy -of this software and associated documentation files (the "Software"), to deal -in the Software without restriction, including without limitation the rights -to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the Software, and to permit persons to whom the Software is -furnished to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in all -copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE -SOFTWARE. diff --git a/lodash._basefilter/README.md b/lodash._basefilter/README.md deleted file mode 100644 index 9a22cb789..000000000 --- a/lodash._basefilter/README.md +++ /dev/null @@ -1,18 +0,0 @@ -# lodash._basefilter v4.0.1 - -The internal [lodash](https://lodash.com/) function `baseFilter` exported as a [Node.js](https://nodejs.org/) module. - -## Installation - -Using npm: -```bash -$ {sudo -H} npm i -g npm -$ npm i --save lodash._basefilter -``` - -In Node.js: -```js -var baseFilter = require('lodash._basefilter'); -``` - -See the [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash._basefilter) for more details. diff --git a/lodash._basefilter/index.js b/lodash._basefilter/index.js deleted file mode 100644 index 31bb85382..000000000 --- a/lodash._basefilter/index.js +++ /dev/null @@ -1,29 +0,0 @@ -/** - * lodash 4.0.1 (Custom Build) - * Build: `lodash modularize exports="npm" -o ./` - * Copyright 2012-2016 The Dojo Foundation - * Based on Underscore.js 1.8.3 - * Copyright 2009-2016 Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors - * Available under MIT license - */ -var baseEach = require('lodash._baseeach'); - -/** - * The base implementation of `_.filter` without support for iteratee shorthands. - * - * @private - * @param {Array|Object} collection The collection to iterate over. - * @param {Function} predicate The function invoked per iteration. - * @returns {Array} Returns the new filtered array. - */ -function baseFilter(collection, predicate) { - var result = []; - baseEach(collection, function(value, index, collection) { - if (predicate(value, index, collection)) { - result.push(value); - } - }); - return result; -} - -module.exports = baseFilter; diff --git a/lodash._basefilter/package.json b/lodash._basefilter/package.json deleted file mode 100644 index 424ea87c8..000000000 --- a/lodash._basefilter/package.json +++ /dev/null @@ -1,19 +0,0 @@ -{ - "name": "lodash._basefilter", - "version": "4.0.1", - "description": "The internal lodash function `baseFilter` exported as a module.", - "homepage": "https://lodash.com/", - "icon": "https://lodash.com/icon.svg", - "license": "MIT", - "author": "John-David Dalton (http://allyoucanleet.com/)", - "contributors": [ - "John-David Dalton (http://allyoucanleet.com/)", - "Blaine Bublitz (https://github.com/phated)", - "Mathias Bynens (https://mathiasbynens.be/)" - ], - "repository": "lodash/lodash", - "scripts": { "test": "echo \"See https://travis-ci.org/lodash/lodash-cli for testing details.\"" }, - "dependencies": { - "lodash._baseeach": "~4.1.0" - } -} diff --git a/lodash._baseisequal/README.md b/lodash._baseisequal/README.md index c986233f1..89d7ae4ae 100644 --- a/lodash._baseisequal/README.md +++ b/lodash._baseisequal/README.md @@ -1,4 +1,4 @@ -# lodash._baseisequal v4.0.1 +# lodash._baseisequal v4.0.2 The internal [lodash](https://lodash.com/) function `baseIsEqual` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var baseIsEqual = require('lodash._baseisequal'); ``` -See the [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash._baseisequal) for more details. +See the [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash._baseisequal) for more details. diff --git a/lodash._baseisequal/index.js b/lodash._baseisequal/index.js index 91edb30b0..b046b9c7e 100644 --- a/lodash._baseisequal/index.js +++ b/lodash._baseisequal/index.js @@ -1,5 +1,5 @@ /** - * lodash 4.0.0 (Custom Build) + * lodash 4.0.2 (Custom Build) * Build: `lodash modularize exports="npm" -o ./` * Copyright 2012-2016 The Dojo Foundation * Based on Underscore.js 1.8.3 @@ -161,7 +161,7 @@ var reIsNative = RegExp('^' + ); /** Built-in value references. */ -var _Symbol = global.Symbol, +var Symbol = global.Symbol, Uint8Array = global.Uint8Array, getPrototypeOf = Object.getPrototypeOf; @@ -174,8 +174,8 @@ var mapCtorString = Map ? funcToString.call(Map) : '', setCtorString = Set ? funcToString.call(Set) : ''; /** Used to convert symbols to primitives and strings. */ -var symbolProto = _Symbol ? _Symbol.prototype : undefined, - symbolValueOf = _Symbol ? symbolProto.valueOf : undefined; +var symbolProto = Symbol ? Symbol.prototype : undefined, + symbolValueOf = Symbol ? symbolProto.valueOf : undefined; /** * The base implementation of `_.has` without support for deep paths. @@ -398,7 +398,7 @@ function equalByTag(object, other, tag, equalFunc, customizer, bitmask) { equalFunc(convert(object), convert(other), customizer, bitmask | UNORDERED_COMPARE_FLAG); case symbolTag: - return !!_Symbol && (symbolValueOf.call(object) == symbolValueOf.call(other)); + return !!Symbol && (symbolValueOf.call(object) == symbolValueOf.call(other)); } return false; } @@ -418,7 +418,6 @@ function equalByTag(object, other, tag, equalFunc, customizer, bitmask) { */ function equalObjects(object, other, equalFunc, customizer, bitmask, stack) { var isPartial = bitmask & PARTIAL_COMPARE_FLAG, - isUnordered = bitmask & UNORDERED_COMPARE_FLAG, objProps = keys(object), objLength = objProps.length, othProps = keys(other), @@ -430,8 +429,7 @@ function equalObjects(object, other, equalFunc, customizer, bitmask, stack) { var index = objLength; while (index--) { var key = objProps[index]; - if (!(isPartial ? key in other : baseHas(other, key)) || - !(isUnordered || key == othProps[index])) { + if (!(isPartial ? key in other : baseHas(other, key))) { return false; } } @@ -624,8 +622,6 @@ function isLength(value) { * // => false */ function isObject(value) { - // Avoid a V8 JIT bug in Chrome 19-20. - // See https://code.google.com/p/v8/issues/detail?id=2291 for more details. var type = typeof value; return !!value && (type == 'object' || type == 'function'); } diff --git a/lodash._baseisequal/package.json b/lodash._baseisequal/package.json index 5dedd0263..8cb62e50f 100644 --- a/lodash._baseisequal/package.json +++ b/lodash._baseisequal/package.json @@ -1,6 +1,6 @@ { "name": "lodash._baseisequal", - "version": "4.0.1", + "version": "4.0.2", "description": "The internal lodash function `baseIsEqual` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", diff --git a/lodash._baseismatch/README.md b/lodash._baseismatch/README.md index 8d7469c57..7ba7d29cc 100644 --- a/lodash._baseismatch/README.md +++ b/lodash._baseismatch/README.md @@ -1,4 +1,4 @@ -# lodash._baseismatch v4.0.1 +# lodash._baseismatch v4.0.2 The internal [lodash](https://lodash.com/) function `baseIsMatch` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var baseIsMatch = require('lodash._baseismatch'); ``` -See the [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash._baseismatch) for more details. +See the [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash._baseismatch) for more details. diff --git a/lodash._baseismatch/index.js b/lodash._baseismatch/index.js index 29179b2b5..b63fed8ce 100644 --- a/lodash._baseismatch/index.js +++ b/lodash._baseismatch/index.js @@ -1,5 +1,5 @@ /** - * lodash 4.0.0 (Custom Build) + * lodash 4.0.2 (Custom Build) * Build: `lodash modularize exports="npm" -o ./` * Copyright 2012-2016 The Dojo Foundation * Based on Underscore.js 1.8.3 @@ -55,7 +55,10 @@ function baseIsMatch(object, source, matchData, customizer) { var stack = new Stack, result = customizer ? customizer(objValue, srcValue, key, object, source, stack) : undefined; - if (!(result === undefined ? baseIsEqual(srcValue, objValue, customizer, UNORDERED_COMPARE_FLAG | PARTIAL_COMPARE_FLAG, stack) : result)) { + if (!(result === undefined + ? baseIsEqual(srcValue, objValue, customizer, UNORDERED_COMPARE_FLAG | PARTIAL_COMPARE_FLAG, stack) + : result + )) { return false; } } diff --git a/lodash._baseismatch/package.json b/lodash._baseismatch/package.json index 3a5f247d6..0d98ea714 100644 --- a/lodash._baseismatch/package.json +++ b/lodash._baseismatch/package.json @@ -1,6 +1,6 @@ { "name": "lodash._baseismatch", - "version": "4.0.1", + "version": "4.0.2", "description": "The internal lodash function `baseIsMatch` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", diff --git a/lodash._basepullat/README.md b/lodash._basepullat/README.md index 6485289be..24047a90c 100644 --- a/lodash._basepullat/README.md +++ b/lodash._basepullat/README.md @@ -1,4 +1,4 @@ -# lodash._basepullat v4.0.1 +# lodash._basepullat v4.0.2 The internal [lodash](https://lodash.com/) function `basePullAt` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var basePullAt = require('lodash._basepullat'); ``` -See the [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash._basepullat) for more details. +See the [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash._basepullat) for more details. diff --git a/lodash._basepullat/index.js b/lodash._basepullat/index.js index d12e62f22..b4f49c84e 100644 --- a/lodash._basepullat/index.js +++ b/lodash._basepullat/index.js @@ -1,5 +1,5 @@ /** - * lodash 4.0.1 (Custom Build) + * lodash 4.0.2 (Custom Build) * Build: `lodash modularize exports="npm" -o ./` * Copyright 2012-2016 The Dojo Foundation * Based on Underscore.js 1.8.3 @@ -27,6 +27,49 @@ var reEscapeChar = /\\(\\)?/g; /** Used to detect unsigned integer values. */ var reIsUint = /^(?:0|[1-9]\d*)$/; +/** Used to determine if values are of the language type `Object`. */ +var objectTypes = { + 'function': true, + 'object': true +}; + +/** Detect free variable `exports`. */ +var freeExports = (objectTypes[typeof exports] && exports && !exports.nodeType) ? exports : null; + +/** Detect free variable `module`. */ +var freeModule = (objectTypes[typeof module] && module && !module.nodeType) ? module : null; + +/** Detect free variable `global` from Node.js. */ +var freeGlobal = checkGlobal(freeExports && freeModule && typeof global == 'object' && global); + +/** Detect free variable `self`. */ +var freeSelf = checkGlobal(objectTypes[typeof self] && self); + +/** Detect free variable `window`. */ +var freeWindow = checkGlobal(objectTypes[typeof window] && window); + +/** Detect `this` as the global object. */ +var thisGlobal = checkGlobal(objectTypes[typeof this] && this); + +/** + * Used as a reference to the global object. + * + * The `this` value is used if it's the global object to avoid Greasemonkey's + * restricted `window` object, otherwise the `window` object is used. + */ +var root = freeGlobal || ((freeWindow !== (thisGlobal && thisGlobal.window)) && freeWindow) || freeSelf || thisGlobal || Function('return this')(); + +/** + * Checks if `value` is a global object. + * + * @private + * @param {*} value The value to check. + * @returns {null|Object} Returns `value` if it's a global object, else `null`. + */ +function checkGlobal(value) { + return (value && value.Object === Object) ? value : null; +} + /** * Checks if `value` is a valid array-like index. * @@ -42,8 +85,8 @@ function isIndex(value, length) { } /** Used for built-in method references. */ -var arrayProto = global.Array.prototype, - objectProto = global.Object.prototype; +var arrayProto = Array.prototype, + objectProto = Object.prototype; /** * Used to resolve the [`toStringTag`](http://ecma-international.org/ecma-262/6.0/#sec-object.prototype.tostring) @@ -52,7 +95,7 @@ var arrayProto = global.Array.prototype, var objectToString = objectProto.toString; /** Built-in value references. */ -var Symbol = global.Symbol, +var Symbol = root.Symbol, splice = arrayProto.splice; /** Used to convert symbols to primitives and strings. */ diff --git a/lodash._basepullat/package.json b/lodash._basepullat/package.json index bd1096e64..b3c33145d 100644 --- a/lodash._basepullat/package.json +++ b/lodash._basepullat/package.json @@ -1,6 +1,6 @@ { "name": "lodash._basepullat", - "version": "4.0.1", + "version": "4.0.2", "description": "The internal lodash function `basePullAt` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", diff --git a/lodash._baseset/README.md b/lodash._baseset/README.md index 7c8403458..e40492c50 100644 --- a/lodash._baseset/README.md +++ b/lodash._baseset/README.md @@ -1,4 +1,4 @@ -# lodash._baseset v4.0.1 +# lodash._baseset v4.0.2 The internal [lodash](https://lodash.com/) function `baseSet` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var baseSet = require('lodash._baseset'); ``` -See the [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash._baseset) for more details. +See the [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash._baseset) for more details. diff --git a/lodash._baseset/index.js b/lodash._baseset/index.js index db336e189..e903038a6 100644 --- a/lodash._baseset/index.js +++ b/lodash._baseset/index.js @@ -1,5 +1,5 @@ /** - * lodash 4.0.1 (Custom Build) + * lodash 4.0.2 (Custom Build) * Build: `lodash modularize exports="npm" -o ./` * Copyright 2012-2016 The Dojo Foundation * Based on Underscore.js 1.8.3 @@ -25,6 +25,49 @@ var reEscapeChar = /\\(\\)?/g; /** Used to detect unsigned integer values. */ var reIsUint = /^(?:0|[1-9]\d*)$/; +/** Used to determine if values are of the language type `Object`. */ +var objectTypes = { + 'function': true, + 'object': true +}; + +/** Detect free variable `exports`. */ +var freeExports = (objectTypes[typeof exports] && exports && !exports.nodeType) ? exports : null; + +/** Detect free variable `module`. */ +var freeModule = (objectTypes[typeof module] && module && !module.nodeType) ? module : null; + +/** Detect free variable `global` from Node.js. */ +var freeGlobal = checkGlobal(freeExports && freeModule && typeof global == 'object' && global); + +/** Detect free variable `self`. */ +var freeSelf = checkGlobal(objectTypes[typeof self] && self); + +/** Detect free variable `window`. */ +var freeWindow = checkGlobal(objectTypes[typeof window] && window); + +/** Detect `this` as the global object. */ +var thisGlobal = checkGlobal(objectTypes[typeof this] && this); + +/** + * Used as a reference to the global object. + * + * The `this` value is used if it's the global object to avoid Greasemonkey's + * restricted `window` object, otherwise the `window` object is used. + */ +var root = freeGlobal || ((freeWindow !== (thisGlobal && thisGlobal.window)) && freeWindow) || freeSelf || thisGlobal || Function('return this')(); + +/** + * Checks if `value` is a global object. + * + * @private + * @param {*} value The value to check. + * @returns {null|Object} Returns `value` if it's a global object, else `null`. + */ +function checkGlobal(value) { + return (value && value.Object === Object) ? value : null; +} + /** * Checks if `value` is a valid array-like index. * @@ -40,7 +83,7 @@ function isIndex(value, length) { } /** Used for built-in method references. */ -var objectProto = global.Object.prototype; +var objectProto = Object.prototype; /** Used to check objects for own properties. */ var hasOwnProperty = objectProto.hasOwnProperty; @@ -52,7 +95,7 @@ var hasOwnProperty = objectProto.hasOwnProperty; var objectToString = objectProto.toString; /** Built-in value references. */ -var Symbol = global.Symbol; +var Symbol = root.Symbol; /** Used to convert symbols to primitives and strings. */ var symbolProto = Symbol ? Symbol.prototype : undefined, diff --git a/lodash._baseset/package.json b/lodash._baseset/package.json index 1ea94e56c..d163230db 100644 --- a/lodash._baseset/package.json +++ b/lodash._baseset/package.json @@ -1,6 +1,6 @@ { "name": "lodash._baseset", - "version": "4.0.1", + "version": "4.0.2", "description": "The internal lodash function `baseSet` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", diff --git a/lodash._basesortedindexby/LICENSE b/lodash._basesortedindexby/LICENSE deleted file mode 100644 index e0c69d560..000000000 --- a/lodash._basesortedindexby/LICENSE +++ /dev/null @@ -1,47 +0,0 @@ -Copyright jQuery Foundation and other contributors - -Based on Underscore.js, copyright Jeremy Ashkenas, -DocumentCloud and Investigative Reporters & Editors - -This software consists of voluntary contributions made by many -individuals. For exact contribution history, see the revision history -available at https://github.com/lodash/lodash - -The following license applies to all parts of this software except as -documented below: - -==== - -Permission is hereby granted, free of charge, to any person obtaining -a copy of this software and associated documentation files (the -"Software"), to deal in the Software without restriction, including -without limitation the rights to use, copy, modify, merge, publish, -distribute, sublicense, and/or sell copies of the Software, and to -permit persons to whom the Software is furnished to do so, subject to -the following conditions: - -The above copyright notice and this permission notice shall be -included in all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, -EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND -NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE -LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION -OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION -WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. - -==== - -Copyright and related rights for sample code are waived via CC0. Sample -code is defined as all source code displayed within the prose of the -documentation. - -CC0: http://creativecommons.org/publicdomain/zero/1.0/ - -==== - -Files located in the node_modules and vendor directories are externally -maintained libraries used by this software which have their own -licenses; we recommend you read them, as their terms may differ from the -terms above. diff --git a/lodash._basesortedindexby/README.md b/lodash._basesortedindexby/README.md deleted file mode 100644 index d79179df6..000000000 --- a/lodash._basesortedindexby/README.md +++ /dev/null @@ -1,18 +0,0 @@ -# lodash._basesortedindexby v4.0.1 - -The internal [lodash](https://lodash.com/) function `baseSortedIndexBy` exported as a [Node.js](https://nodejs.org/) module. - -## Installation - -Using npm: -```bash -$ {sudo -H} npm i -g npm -$ npm i --save lodash._basesortedindexby -``` - -In Node.js: -```js -var baseSortedIndexBy = require('lodash._basesortedindexby'); -``` - -See the [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash._basesortedindexby) for more details. diff --git a/lodash._basesortedindexby/index.js b/lodash._basesortedindexby/index.js deleted file mode 100644 index e1f5801c1..000000000 --- a/lodash._basesortedindexby/index.js +++ /dev/null @@ -1,135 +0,0 @@ -/** - * lodash (Custom Build) - * Build: `lodash modularize exports="npm" -o ./` - * Copyright jQuery Foundation and other contributors - * Released under MIT license - * Based on Underscore.js 1.8.3 - * Copyright Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors - */ - -/** Used as references for the maximum length and index of an array. */ -var MAX_ARRAY_LENGTH = 4294967295, - MAX_ARRAY_INDEX = MAX_ARRAY_LENGTH - 1; - -/** `Object#toString` result references. */ -var symbolTag = '[object Symbol]'; - -/** Used for built-in method references. */ -var objectProto = Object.prototype; - -/** - * Used to resolve the - * [`toStringTag`](http://ecma-international.org/ecma-262/6.0/#sec-object.prototype.tostring) - * of values. - */ -var objectToString = objectProto.toString; - -/* Built-in method references for those with the same name as other `lodash` methods. */ -var nativeFloor = Math.floor, - nativeMin = Math.min; - -/** - * The base implementation of `_.sortedIndexBy` and `_.sortedLastIndexBy` - * which invokes `iteratee` for `value` and each element of `array` to compute - * their sort ranking. The iteratee is invoked with one argument; (value). - * - * @private - * @param {Array} array The sorted array to inspect. - * @param {*} value The value to evaluate. - * @param {Function} iteratee The iteratee invoked per element. - * @param {boolean} [retHighest] Specify returning the highest qualified index. - * @returns {number} Returns the index at which `value` should be inserted - * into `array`. - */ -function baseSortedIndexBy(array, value, iteratee, retHighest) { - value = iteratee(value); - - var low = 0, - high = array ? array.length : 0, - valIsNaN = value !== value, - valIsNull = value === null, - valIsSymbol = isSymbol(value), - valIsUndefined = value === undefined; - - while (low < high) { - var mid = nativeFloor((low + high) / 2), - computed = iteratee(array[mid]), - othIsDefined = computed !== undefined, - othIsNull = computed === null, - othIsReflexive = computed === computed, - othIsSymbol = isSymbol(computed); - - if (valIsNaN) { - var setLow = retHighest || othIsReflexive; - } else if (valIsUndefined) { - setLow = othIsReflexive && (retHighest || othIsDefined); - } else if (valIsNull) { - setLow = othIsReflexive && othIsDefined && (retHighest || !othIsNull); - } else if (valIsSymbol) { - setLow = othIsReflexive && othIsDefined && !othIsNull && (retHighest || !othIsSymbol); - } else if (othIsNull || othIsSymbol) { - setLow = false; - } else { - setLow = retHighest ? (computed <= value) : (computed < value); - } - if (setLow) { - low = mid + 1; - } else { - high = mid; - } - } - return nativeMin(high, MAX_ARRAY_INDEX); -} - -/** - * Checks if `value` is object-like. A value is object-like if it's not `null` - * and has a `typeof` result of "object". - * - * @static - * @memberOf _ - * @since 4.0.0 - * @category Lang - * @param {*} value The value to check. - * @returns {boolean} Returns `true` if `value` is object-like, else `false`. - * @example - * - * _.isObjectLike({}); - * // => true - * - * _.isObjectLike([1, 2, 3]); - * // => true - * - * _.isObjectLike(_.noop); - * // => false - * - * _.isObjectLike(null); - * // => false - */ -function isObjectLike(value) { - return !!value && typeof value == 'object'; -} - -/** - * Checks if `value` is classified as a `Symbol` primitive or object. - * - * @static - * @memberOf _ - * @since 4.0.0 - * @category Lang - * @param {*} value The value to check. - * @returns {boolean} Returns `true` if `value` is correctly classified, - * else `false`. - * @example - * - * _.isSymbol(Symbol.iterator); - * // => true - * - * _.isSymbol('abc'); - * // => false - */ -function isSymbol(value) { - return typeof value == 'symbol' || - (isObjectLike(value) && objectToString.call(value) == symbolTag); -} - -module.exports = baseSortedIndexBy; diff --git a/lodash._basesortedindexby/package.json b/lodash._basesortedindexby/package.json deleted file mode 100644 index c91261836..000000000 --- a/lodash._basesortedindexby/package.json +++ /dev/null @@ -1,16 +0,0 @@ -{ - "name": "lodash._basesortedindexby", - "version": "4.0.1", - "description": "The internal lodash function `baseSortedIndexBy` exported as a module.", - "homepage": "https://lodash.com/", - "icon": "https://lodash.com/icon.svg", - "license": "MIT", - "author": "John-David Dalton (http://allyoucanleet.com/)", - "contributors": [ - "John-David Dalton (http://allyoucanleet.com/)", - "Blaine Bublitz (https://github.com/phated)", - "Mathias Bynens (https://mathiasbynens.be/)" - ], - "repository": "lodash/lodash", - "scripts": { "test": "echo \"See https://travis-ci.org/lodash/lodash-cli for testing details.\"" } -} diff --git a/lodash._basesorteduniqby/LICENSE b/lodash._basesorteduniqby/LICENSE deleted file mode 100644 index bcbe13d67..000000000 --- a/lodash._basesorteduniqby/LICENSE +++ /dev/null @@ -1,23 +0,0 @@ -The MIT License (MIT) - -Copyright 2012-2016 The Dojo Foundation -Based on Underscore.js, copyright 2009-2016 Jeremy Ashkenas, -DocumentCloud and Investigative Reporters & Editors - -Permission is hereby granted, free of charge, to any person obtaining a copy -of this software and associated documentation files (the "Software"), to deal -in the Software without restriction, including without limitation the rights -to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the Software, and to permit persons to whom the Software is -furnished to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in all -copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE -SOFTWARE. diff --git a/lodash._basesorteduniqby/README.md b/lodash._basesorteduniqby/README.md deleted file mode 100644 index 5c3522296..000000000 --- a/lodash._basesorteduniqby/README.md +++ /dev/null @@ -1,18 +0,0 @@ -# lodash._basesorteduniqby v4.0.1 - -The internal [lodash](https://lodash.com/) function `baseSortedUniqBy` exported as a [Node.js](https://nodejs.org/) module. - -## Installation - -Using npm: -```bash -$ {sudo -H} npm i -g npm -$ npm i --save lodash._basesorteduniqby -``` - -In Node.js: -```js -var baseSortedUniqBy = require('lodash._basesorteduniqby'); -``` - -See the [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash._basesorteduniqby) for more details. diff --git a/lodash._basesorteduniqby/index.js b/lodash._basesorteduniqby/index.js deleted file mode 100644 index 9072b5509..000000000 --- a/lodash._basesorteduniqby/index.js +++ /dev/null @@ -1,76 +0,0 @@ -/** - * lodash 4.0.1 (Custom Build) - * Build: `lodash modularize exports="npm" -o ./` - * Copyright 2012-2016 The Dojo Foundation - * Based on Underscore.js 1.8.3 - * Copyright 2009-2016 Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors - * Available under MIT license - */ - -/** - * The base implementation of `_.sortedUniqBy` without support for iteratee - * shorthands. - * - * @private - * @param {Array} array The array to inspect. - * @param {Function} [iteratee] The iteratee invoked per element. - * @returns {Array} Returns the new duplicate free array. - */ -function baseSortedUniqBy(array, iteratee) { - var index = 0, - length = array.length, - value = array[0], - computed = iteratee ? iteratee(value) : value, - seen = computed, - resIndex = 1, - result = [value]; - - while (++index < length) { - value = array[index], - computed = iteratee ? iteratee(value) : value; - - if (!eq(computed, seen)) { - seen = computed; - result[resIndex++] = value; - } - } - return result; -} - -/** - * Performs a - * [`SameValueZero`](http://ecma-international.org/ecma-262/6.0/#sec-samevaluezero) - * comparison between two values to determine if they are equivalent. - * - * @static - * @memberOf _ - * @since 4.0.0 - * @category Lang - * @param {*} value The value to compare. - * @param {*} other The other value to compare. - * @returns {boolean} Returns `true` if the values are equivalent, else `false`. - * @example - * - * var object = { 'user': 'fred' }; - * var other = { 'user': 'fred' }; - * - * _.eq(object, object); - * // => true - * - * _.eq(object, other); - * // => false - * - * _.eq('a', 'a'); - * // => true - * - * _.eq('a', Object('a')); - * // => false - * - * _.eq(NaN, NaN); - * // => true - */ -function eq(value, other) { - return value === other || (value !== value && other !== other); -} - -module.exports = baseSortedUniqBy; diff --git a/lodash._basesorteduniqby/package.json b/lodash._basesorteduniqby/package.json deleted file mode 100644 index 945c4bc8a..000000000 --- a/lodash._basesorteduniqby/package.json +++ /dev/null @@ -1,16 +0,0 @@ -{ - "name": "lodash._basesorteduniqby", - "version": "4.0.1", - "description": "The internal lodash function `baseSortedUniqBy` exported as a module.", - "homepage": "https://lodash.com/", - "icon": "https://lodash.com/icon.svg", - "license": "MIT", - "author": "John-David Dalton (http://allyoucanleet.com/)", - "contributors": [ - "John-David Dalton (http://allyoucanleet.com/)", - "Blaine Bublitz (https://github.com/phated)", - "Mathias Bynens (https://mathiasbynens.be/)" - ], - "repository": "lodash/lodash", - "scripts": { "test": "echo \"See https://travis-ci.org/lodash/lodash-cli for testing details.\"" } -} diff --git a/lodash._createset/LICENSE b/lodash._createset/LICENSE index bcbe13d67..e0c69d560 100644 --- a/lodash._createset/LICENSE +++ b/lodash._createset/LICENSE @@ -1,23 +1,47 @@ -The MIT License (MIT) +Copyright jQuery Foundation and other contributors -Copyright 2012-2016 The Dojo Foundation -Based on Underscore.js, copyright 2009-2016 Jeremy Ashkenas, +Based on Underscore.js, copyright Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors -Permission is hereby granted, free of charge, to any person obtaining a copy -of this software and associated documentation files (the "Software"), to deal -in the Software without restriction, including without limitation the rights -to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the Software, and to permit persons to whom the Software is -furnished to do so, subject to the following conditions: +This software consists of voluntary contributions made by many +individuals. For exact contribution history, see the revision history +available at https://github.com/lodash/lodash -The above copyright notice and this permission notice shall be included in all -copies or substantial portions of the Software. +The following license applies to all parts of this software except as +documented below: -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE -SOFTWARE. +==== + +Permission is hereby granted, free of charge, to any person obtaining +a copy of this software and associated documentation files (the +"Software"), to deal in the Software without restriction, including +without limitation the rights to use, copy, modify, merge, publish, +distribute, sublicense, and/or sell copies of the Software, and to +permit persons to whom the Software is furnished to do so, subject to +the following conditions: + +The above copyright notice and this permission notice shall be +included in all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, +EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF +MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND +NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE +LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION +OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION +WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + +==== + +Copyright and related rights for sample code are waived via CC0. Sample +code is defined as all source code displayed within the prose of the +documentation. + +CC0: http://creativecommons.org/publicdomain/zero/1.0/ + +==== + +Files located in the node_modules and vendor directories are externally +maintained libraries used by this software which have their own +licenses; we recommend you read them, as their terms may differ from the +terms above. diff --git a/lodash._createset/README.md b/lodash._createset/README.md index fe6cc9b51..4d2ffbf21 100644 --- a/lodash._createset/README.md +++ b/lodash._createset/README.md @@ -1,4 +1,4 @@ -# lodash._createset v4.0.1 +# lodash._createset v4.0.2 The internal [lodash](https://lodash.com/) function `createSet` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var createSet = require('lodash._createset'); ``` -See the [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash._createset) for more details. +See the [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash._createset) for more details. diff --git a/lodash._createset/index.js b/lodash._createset/index.js index 7a10c3c3b..a4dcacb9b 100644 --- a/lodash._createset/index.js +++ b/lodash._createset/index.js @@ -1,17 +1,20 @@ /** - * lodash 4.0.1 (Custom Build) + * lodash 4.0.2 (Custom Build) * Build: `lodash modularize exports="npm" -o ./` - * Copyright 2012-2016 The Dojo Foundation + * Copyright jQuery Foundation and other contributors + * Released under MIT license * Based on Underscore.js 1.8.3 - * Copyright 2009-2016 Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors - * Available under MIT license + * Copyright Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors */ /** `Object#toString` result references. */ var funcTag = '[object Function]', genTag = '[object GeneratorFunction]'; -/** Used to match `RegExp` [syntax characters](http://ecma-international.org/ecma-262/6.0/#sec-patterns). */ +/** + * Used to match `RegExp` + * [syntax characters](http://ecma-international.org/ecma-262/6.0/#sec-patterns). + */ var reRegExpChar = /[\\^$.*+?()[\]{}|]/g; /** Used to detect host constructors (Safari). */ @@ -95,7 +98,8 @@ var funcToString = Function.prototype.toString; var hasOwnProperty = objectProto.hasOwnProperty; /** - * Used to resolve the [`toStringTag`](http://ecma-international.org/ecma-262/6.0/#sec-object.prototype.tostring) + * Used to resolve the + * [`toStringTag`](http://ecma-international.org/ecma-262/6.0/#sec-object.prototype.tostring) * of values. */ var objectToString = objectProto.toString; @@ -133,6 +137,25 @@ function getNative(object, key) { return isNative(value) ? value : undefined; } +/** + * Converts `func` to its source code. + * + * @private + * @param {Function} func The function to process. + * @returns {string} Returns the source code. + */ +function toSource(func) { + if (func != null) { + try { + return funcToString.call(func); + } catch (e) {} + try { + return (func + ''); + } catch (e) {} + } + return ''; +} + /** * Checks if `value` is classified as a `Function` object. * @@ -160,8 +183,9 @@ function isFunction(value) { } /** - * Checks if `value` is the [language type](https://es5.github.io/#x8) of `Object`. - * (e.g. arrays, functions, objects, regexes, `new Number(0)`, and `new String('')`) + * Checks if `value` is the + * [language type](http://www.ecma-international.org/ecma-262/6.0/#sec-ecmascript-language-types) + * of `Object`. (e.g. arrays, functions, objects, regexes, `new Number(0)`, and `new String('')`) * * @static * @memberOf _ @@ -188,34 +212,6 @@ function isObject(value) { return !!value && (type == 'object' || type == 'function'); } -/** - * Checks if `value` is object-like. A value is object-like if it's not `null` - * and has a `typeof` result of "object". - * - * @static - * @memberOf _ - * @since 4.0.0 - * @category Lang - * @param {*} value The value to check. - * @returns {boolean} Returns `true` if `value` is object-like, else `false`. - * @example - * - * _.isObjectLike({}); - * // => true - * - * _.isObjectLike([1, 2, 3]); - * // => true - * - * _.isObjectLike(_.noop); - * // => false - * - * _.isObjectLike(null); - * // => false - */ -function isObjectLike(value) { - return !!value && typeof value == 'object'; -} - /** * Checks if `value` is a native function. * @@ -235,14 +231,11 @@ function isObjectLike(value) { * // => false */ function isNative(value) { - if (value == null) { + if (!isObject(value)) { return false; } - if (isFunction(value)) { - return reIsNative.test(funcToString.call(value)); - } - return isObjectLike(value) && - (isHostObject(value) ? reIsNative : reIsHostCtor).test(value); + var pattern = (isFunction(value) || isHostObject(value)) ? reIsNative : reIsHostCtor; + return pattern.test(toSource(value)); } /** diff --git a/lodash._createset/package.json b/lodash._createset/package.json index 019e606ee..c51c8714f 100644 --- a/lodash._createset/package.json +++ b/lodash._createset/package.json @@ -1,6 +1,6 @@ { "name": "lodash._createset", - "version": "4.0.1", + "version": "4.0.2", "description": "The internal lodash function `createSet` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", diff --git a/lodash._createwrapper/README.md b/lodash._createwrapper/README.md index bd52eee41..4670f181b 100644 --- a/lodash._createwrapper/README.md +++ b/lodash._createwrapper/README.md @@ -1,4 +1,4 @@ -# lodash._createwrapper v4.0.1 +# lodash._createwrapper v4.0.2 The internal [lodash](https://lodash.com/) function `createWrapper` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var createWrapper = require('lodash._createwrapper'); ``` -See the [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash._createwrapper) for more details. +See the [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash._createwrapper) for more details. diff --git a/lodash._createwrapper/index.js b/lodash._createwrapper/index.js index a4fc6d757..dba9d6e0f 100644 --- a/lodash._createwrapper/index.js +++ b/lodash._createwrapper/index.js @@ -1,5 +1,5 @@ /** - * lodash 4.0.1 (Custom Build) + * lodash 4.0.2 (Custom Build) * Build: `lodash modularize exports="npm" -o ./` * Copyright 2012-2016 The Dojo Foundation * Based on Underscore.js 1.8.3 @@ -7,6 +7,12 @@ * Available under MIT license */ +/** Used as the `TypeError` message for "Functions" methods. */ +var FUNC_ERROR_TEXT = 'Expected a function'; + +/** Used as the internal argument placeholder. */ +var PLACEHOLDER = '__lodash_placeholder__'; + /** Used to compose bitmasks for wrapper metadata. */ var BIND_FLAG = 1, BIND_KEY_FLAG = 2, @@ -18,18 +24,12 @@ var BIND_FLAG = 1, ARY_FLAG = 128, FLIP_FLAG = 512; -/** Used as the `TypeError` message for "Functions" methods. */ -var FUNC_ERROR_TEXT = 'Expected a function'; - /** Used as references for various `Number` constants. */ var INFINITY = 1 / 0, MAX_SAFE_INTEGER = 9007199254740991, MAX_INTEGER = 1.7976931348623157e+308, NAN = 0 / 0; -/** Used as the internal argument placeholder. */ -var PLACEHOLDER = '__lodash_placeholder__'; - /** `Object#toString` result references. */ var funcTag = '[object Function]', genTag = '[object GeneratorFunction]'; @@ -168,14 +168,14 @@ function isIndex(value, length) { function replaceHolders(array, placeholder) { var index = -1, length = array.length, - resIndex = -1, + resIndex = 0, result = []; while (++index < length) { var value = array[index]; if (value === placeholder || value === PLACEHOLDER) { array[index] = PLACEHOLDER; - result[++resIndex] = index; + result[resIndex++] = index; } } return result; @@ -660,8 +660,8 @@ function reorder(array, indexes) { */ function isFunction(value) { // The use of `Object#toString` avoids issues with the `typeof` operator - // in Safari 8 which returns 'object' for typed array constructors, and - // PhantomJS 1.9 which returns 'function' for `NodeList` instances. + // in Safari 8 which returns 'object' for typed array and weak map constructors, + // and PhantomJS 1.9 which returns 'function' for `NodeList` instances. var tag = isObject(value) ? objectToString.call(value) : ''; return tag == funcTag || tag == genTag; } diff --git a/lodash._createwrapper/package.json b/lodash._createwrapper/package.json index a9a86d716..446ba5bee 100644 --- a/lodash._createwrapper/package.json +++ b/lodash._createwrapper/package.json @@ -1,6 +1,6 @@ { "name": "lodash._createwrapper", - "version": "4.0.1", + "version": "4.0.2", "description": "The internal lodash function `createWrapper` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", @@ -8,7 +8,7 @@ "author": "John-David Dalton (http://allyoucanleet.com/)", "contributors": [ "John-David Dalton (http://allyoucanleet.com/)", - "Blaine Bublitz (https://github.com/phated)", + "Blaine Bublitz (https://github.com/phated)", "Mathias Bynens (https://mathiasbynens.be/)" ], "repository": "lodash/lodash", diff --git a/lodash._setcache/LICENSE b/lodash._setcache/LICENSE index b054ca5a3..bcbe13d67 100644 --- a/lodash._setcache/LICENSE +++ b/lodash._setcache/LICENSE @@ -1,22 +1,23 @@ +The MIT License (MIT) + Copyright 2012-2016 The Dojo Foundation Based on Underscore.js, copyright 2009-2016 Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors -Permission is hereby granted, free of charge, to any person obtaining -a copy of this software and associated documentation files (the -"Software"), to deal in the Software without restriction, including -without limitation the rights to use, copy, modify, merge, publish, -distribute, sublicense, and/or sell copies of the Software, and to -permit persons to whom the Software is furnished to do so, subject to -the following conditions: +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: -The above copyright notice and this permission notice shall be -included in all copies or substantial portions of the Software. +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, -EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND -NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE -LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION -OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION -WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. diff --git a/lodash._setcache/README.md b/lodash._setcache/README.md index 56265a8fe..9563f7561 100644 --- a/lodash._setcache/README.md +++ b/lodash._setcache/README.md @@ -1,4 +1,4 @@ -# lodash._setcache v4.0.1 +# lodash._setcache v4.0.2 The internal [lodash](https://lodash.com/) function `SetCache` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var SetCache = require('lodash._setcache'); ``` -See the [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash._setcache) for more details. +See the [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash._setcache) for more details. diff --git a/lodash._setcache/index.js b/lodash._setcache/index.js index 45a19c662..32520a8b4 100644 --- a/lodash._setcache/index.js +++ b/lodash._setcache/index.js @@ -1,5 +1,5 @@ /** - * lodash 4.0.0 (Custom Build) + * lodash 4.0.2 (Custom Build) * Build: `lodash modularize exports="npm" -o ./` * Copyright 2012-2016 The Dojo Foundation * Based on Underscore.js 1.8.3 @@ -16,6 +16,7 @@ var HASH_UNDEFINED = '__lodash_hash_undefined__'; * Creates a set cache object to store unique values. * * @private + * @constructor * @param {Array} [values] The values to cache. */ function SetCache(values) { @@ -59,7 +60,7 @@ function cachePush(value) { function isKeyable(value) { var type = typeof value; return type == 'number' || type == 'boolean' || - (type == 'string' && value !== '__proto__') || value == null; + (type == 'string' && value != '__proto__') || value == null; } // Add functions to the `SetCache`. diff --git a/lodash._setcache/package.json b/lodash._setcache/package.json index 3678d8a0d..a05b53f7e 100644 --- a/lodash._setcache/package.json +++ b/lodash._setcache/package.json @@ -1,6 +1,6 @@ { "name": "lodash._setcache", - "version": "4.0.1", + "version": "4.0.2", "description": "The internal lodash function `SetCache` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", diff --git a/lodash._stack/README.md b/lodash._stack/README.md index 7ea070a66..5b65e8eff 100644 --- a/lodash._stack/README.md +++ b/lodash._stack/README.md @@ -1,4 +1,4 @@ -# lodash._stack v4.0.1 +# lodash._stack v4.0.2 The internal [lodash](https://lodash.com/) function `Stack` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var Stack = require('lodash._stack'); ``` -See the [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash._stack) for more details. +See the [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash._stack) for more details. diff --git a/lodash._stack/index.js b/lodash._stack/index.js index fe8a3570b..5a4564adf 100644 --- a/lodash._stack/index.js +++ b/lodash._stack/index.js @@ -1,5 +1,5 @@ /** - * lodash 4.0.0 (Custom Build) + * lodash 4.0.2 (Custom Build) * Build: `lodash modularize exports="npm" -o ./` * Copyright 2012-2016 The Dojo Foundation * Based on Underscore.js 1.8.3 @@ -12,7 +12,7 @@ var MapCache = require('lodash._mapcache'); var LARGE_ARRAY_SIZE = 200; /** Used for built-in method references. */ -var arrayProto = global.Array.prototype; +var arrayProto = Array.prototype; /** Built-in value references. */ var splice = arrayProto.splice; @@ -21,6 +21,7 @@ var splice = arrayProto.splice; * Creates a stack cache object to store key-value pairs. * * @private + * @constructor * @param {Array} [values] The values to cache. */ function Stack(values) { diff --git a/lodash._stack/package.json b/lodash._stack/package.json index d4c4398e5..49f78ad86 100644 --- a/lodash._stack/package.json +++ b/lodash._stack/package.json @@ -1,6 +1,6 @@ { "name": "lodash._stack", - "version": "4.0.1", + "version": "4.0.2", "description": "The internal lodash function `Stack` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", diff --git a/lodash.after/LICENSE b/lodash.after/LICENSE index b054ca5a3..e0c69d560 100644 --- a/lodash.after/LICENSE +++ b/lodash.after/LICENSE @@ -1,7 +1,17 @@ -Copyright 2012-2016 The Dojo Foundation -Based on Underscore.js, copyright 2009-2016 Jeremy Ashkenas, +Copyright jQuery Foundation and other contributors + +Based on Underscore.js, copyright Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors +This software consists of voluntary contributions made by many +individuals. For exact contribution history, see the revision history +available at https://github.com/lodash/lodash + +The following license applies to all parts of this software except as +documented below: + +==== + Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including @@ -20,3 +30,18 @@ NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + +==== + +Copyright and related rights for sample code are waived via CC0. Sample +code is defined as all source code displayed within the prose of the +documentation. + +CC0: http://creativecommons.org/publicdomain/zero/1.0/ + +==== + +Files located in the node_modules and vendor directories are externally +maintained libraries used by this software which have their own +licenses; we recommend you read them, as their terms may differ from the +terms above. diff --git a/lodash.after/README.md b/lodash.after/README.md index bcc064e7d..3e34ac6cd 100644 --- a/lodash.after/README.md +++ b/lodash.after/README.md @@ -1,4 +1,4 @@ -# lodash.after v4.0.1 +# lodash.after v4.0.2 The [lodash](https://lodash.com/) method `_.after` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var after = require('lodash.after'); ``` -See the [documentation](https://lodash.com/docs#after) or [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash.after) for more details. +See the [documentation](https://lodash.com/docs#after) or [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash.after) for more details. diff --git a/lodash.after/index.js b/lodash.after/index.js index c8d95644b..fc6ba8dc3 100644 --- a/lodash.after/index.js +++ b/lodash.after/index.js @@ -1,10 +1,10 @@ /** - * lodash 4.0.1 (Custom Build) + * lodash 4.0.2 (Custom Build) * Build: `lodash modularize exports="npm" -o ./` - * Copyright 2012-2016 The Dojo Foundation + * Copyright jQuery Foundation and other contributors + * Released under MIT license * Based on Underscore.js 1.8.3 - * Copyright 2009-2016 Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors - * Available under MIT license + * Copyright Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors */ /** Used as the `TypeError` message for "Functions" methods. */ @@ -17,7 +17,8 @@ var INFINITY = 1 / 0, /** `Object#toString` result references. */ var funcTag = '[object Function]', - genTag = '[object GeneratorFunction]'; + genTag = '[object GeneratorFunction]', + symbolTag = '[object Symbol]'; /** Used to match leading and trailing whitespace. */ var reTrim = /^\s+|\s+$/g; @@ -38,7 +39,8 @@ var freeParseInt = parseInt; var objectProto = Object.prototype; /** - * Used to resolve the [`toStringTag`](http://ecma-international.org/ecma-262/6.0/#sec-object.prototype.tostring) + * Used to resolve the + * [`toStringTag`](http://ecma-international.org/ecma-262/6.0/#sec-object.prototype.tostring) * of values. */ var objectToString = objectProto.toString; @@ -49,6 +51,7 @@ var objectToString = objectProto.toString; * * @static * @memberOf _ + * @since 0.1.0 * @category Function * @param {number} n The number of calls before `func` is invoked. * @param {Function} func The function to restrict. @@ -64,7 +67,7 @@ var objectToString = objectProto.toString; * _.forEach(saves, function(type) { * asyncSave({ 'type': type, 'complete': done }); * }); - * // => logs 'done saving!' after the two async saves have completed + * // => Logs 'done saving!' after the two async saves have completed. */ function after(n, func) { if (typeof func != 'function') { @@ -83,9 +86,11 @@ function after(n, func) { * * @static * @memberOf _ + * @since 0.1.0 * @category Lang * @param {*} value The value to check. - * @returns {boolean} Returns `true` if `value` is correctly classified, else `false`. + * @returns {boolean} Returns `true` if `value` is correctly classified, + * else `false`. * @example * * _.isFunction(_); @@ -103,11 +108,13 @@ function isFunction(value) { } /** - * Checks if `value` is the [language type](https://es5.github.io/#x8) of `Object`. - * (e.g. arrays, functions, objects, regexes, `new Number(0)`, and `new String('')`) + * Checks if `value` is the + * [language type](http://www.ecma-international.org/ecma-262/6.0/#sec-ecmascript-language-types) + * of `Object`. (e.g. arrays, functions, objects, regexes, `new Number(0)`, and `new String('')`) * * @static * @memberOf _ + * @since 0.1.0 * @category Lang * @param {*} value The value to check. * @returns {boolean} Returns `true` if `value` is an object, else `false`. @@ -131,12 +138,65 @@ function isObject(value) { } /** - * Converts `value` to an integer. - * - * **Note:** This function is loosely based on [`ToInteger`](http://www.ecma-international.org/ecma-262/6.0/#sec-tointeger). + * Checks if `value` is object-like. A value is object-like if it's not `null` + * and has a `typeof` result of "object". * * @static * @memberOf _ + * @since 4.0.0 + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is object-like, else `false`. + * @example + * + * _.isObjectLike({}); + * // => true + * + * _.isObjectLike([1, 2, 3]); + * // => true + * + * _.isObjectLike(_.noop); + * // => false + * + * _.isObjectLike(null); + * // => false + */ +function isObjectLike(value) { + return !!value && typeof value == 'object'; +} + +/** + * Checks if `value` is classified as a `Symbol` primitive or object. + * + * @static + * @memberOf _ + * @since 4.0.0 + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is correctly classified, + * else `false`. + * @example + * + * _.isSymbol(Symbol.iterator); + * // => true + * + * _.isSymbol('abc'); + * // => false + */ +function isSymbol(value) { + return typeof value == 'symbol' || + (isObjectLike(value) && objectToString.call(value) == symbolTag); +} + +/** + * Converts `value` to an integer. + * + * **Note:** This function is loosely based on + * [`ToInteger`](http://www.ecma-international.org/ecma-262/6.0/#sec-tointeger). + * + * @static + * @memberOf _ + * @since 4.0.0 * @category Lang * @param {*} value The value to convert. * @returns {number} Returns the converted integer. @@ -172,6 +232,7 @@ function toInteger(value) { * * @static * @memberOf _ + * @since 4.0.0 * @category Lang * @param {*} value The value to process. * @returns {number} Returns the number. @@ -190,6 +251,12 @@ function toInteger(value) { * // => 3 */ function toNumber(value) { + if (typeof value == 'number') { + return value; + } + if (isSymbol(value)) { + return NAN; + } if (isObject(value)) { var other = isFunction(value.valueOf) ? value.valueOf() : value; value = isObject(other) ? (other + '') : other; diff --git a/lodash.after/package.json b/lodash.after/package.json index 956ec40bc..d6f5254e1 100644 --- a/lodash.after/package.json +++ b/lodash.after/package.json @@ -1,6 +1,6 @@ { "name": "lodash.after", - "version": "4.0.1", + "version": "4.0.2", "description": "The lodash method `_.after` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", @@ -9,7 +9,7 @@ "author": "John-David Dalton (http://allyoucanleet.com/)", "contributors": [ "John-David Dalton (http://allyoucanleet.com/)", - "Blaine Bublitz (https://github.com/phated)", + "Blaine Bublitz (https://github.com/phated)", "Mathias Bynens (https://mathiasbynens.be/)" ], "repository": "lodash/lodash", diff --git a/lodash.assign/README.md b/lodash.assign/README.md index 2969540b0..aeb8657f8 100644 --- a/lodash.assign/README.md +++ b/lodash.assign/README.md @@ -1,4 +1,4 @@ -# lodash.assign v4.0.1 +# lodash.assign v4.0.2 The [lodash](https://lodash.com/) method `_.assign` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var assign = require('lodash.assign'); ``` -See the [documentation](https://lodash.com/docs#assign) or [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash.assign) for more details. +See the [documentation](https://lodash.com/docs#assign) or [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash.assign) for more details. diff --git a/lodash.assign/index.js b/lodash.assign/index.js index ae479a1c6..9b1588541 100644 --- a/lodash.assign/index.js +++ b/lodash.assign/index.js @@ -1,5 +1,5 @@ /** - * lodash 4.0.1 (Custom Build) + * lodash 4.0.2 (Custom Build) * Build: `lodash modularize exports="npm" -o ./` * Copyright 2012-2016 The Dojo Foundation * Based on Underscore.js 1.8.3 @@ -34,7 +34,7 @@ function isIndex(value, length) { } /** Used for built-in method references. */ -var objectProto = global.Object.prototype; +var objectProto = Object.prototype; /** Used to check objects for own properties. */ var hasOwnProperty = objectProto.hasOwnProperty; @@ -159,7 +159,7 @@ function createAssigner(assigner) { var getLength = baseProperty('length'); /** - * Checks if the provided arguments are from an iteratee call. + * Checks if the given arguments are from an iteratee call. * * @private * @param {*} value The potential iteratee value argument. diff --git a/lodash.assign/package.json b/lodash.assign/package.json index 2da243614..09073b716 100644 --- a/lodash.assign/package.json +++ b/lodash.assign/package.json @@ -1,11 +1,11 @@ { "name": "lodash.assign", - "version": "4.0.1", + "version": "4.0.2", "description": "The lodash method `_.assign` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", "license": "MIT", - "keywords": "lodash, lodash-modularized, stdlib, util, assign", + "keywords": "lodash-modularized, assign", "author": "John-David Dalton (http://allyoucanleet.com/)", "contributors": [ "John-David Dalton (http://allyoucanleet.com/)", diff --git a/lodash.assignin/README.md b/lodash.assignin/README.md index fd9d859aa..dd083ad6b 100644 --- a/lodash.assignin/README.md +++ b/lodash.assignin/README.md @@ -1,4 +1,4 @@ -# lodash.assignin v4.0.1 +# lodash.assignin v4.0.2 The [lodash](https://lodash.com/) method `_.assignIn` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var assignIn = require('lodash.assignin'); ``` -See the [documentation](https://lodash.com/docs#assignIn) or [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash.assignin) for more details. +See the [documentation](https://lodash.com/docs#assignIn) or [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash.assignin) for more details. diff --git a/lodash.assignin/index.js b/lodash.assignin/index.js index a892edb2d..82f9e9a95 100644 --- a/lodash.assignin/index.js +++ b/lodash.assignin/index.js @@ -1,5 +1,5 @@ /** - * lodash 4.0.1 (Custom Build) + * lodash 4.0.2 (Custom Build) * Build: `lodash modularize exports="npm" -o ./` * Copyright 2012-2016 The Dojo Foundation * Based on Underscore.js 1.8.3 @@ -34,7 +34,7 @@ function isIndex(value, length) { } /** Used for built-in method references. */ -var objectProto = global.Object.prototype; +var objectProto = Object.prototype; /** Used to check objects for own properties. */ var hasOwnProperty = objectProto.hasOwnProperty; @@ -159,7 +159,7 @@ function createAssigner(assigner) { var getLength = baseProperty('length'); /** - * Checks if the provided arguments are from an iteratee call. + * Checks if the given arguments are from an iteratee call. * * @private * @param {*} value The potential iteratee value argument. diff --git a/lodash.assignin/package.json b/lodash.assignin/package.json index 38bdaeec9..a4c671dd5 100644 --- a/lodash.assignin/package.json +++ b/lodash.assignin/package.json @@ -1,11 +1,11 @@ { "name": "lodash.assignin", - "version": "4.0.1", + "version": "4.0.2", "description": "The lodash method `_.assignIn` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", "license": "MIT", - "keywords": "lodash, lodash-modularized, stdlib, util, assignin", + "keywords": "lodash-modularized, assignin", "author": "John-David Dalton (http://allyoucanleet.com/)", "contributors": [ "John-David Dalton (http://allyoucanleet.com/)", diff --git a/lodash.assigninwith/README.md b/lodash.assigninwith/README.md index b0481c334..cd2d595b9 100644 --- a/lodash.assigninwith/README.md +++ b/lodash.assigninwith/README.md @@ -1,4 +1,4 @@ -# lodash.assigninwith v4.0.1 +# lodash.assigninwith v4.0.2 The [lodash](https://lodash.com/) method `_.assignInWith` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var assignInWith = require('lodash.assigninwith'); ``` -See the [documentation](https://lodash.com/docs#assignInWith) or [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash.assigninwith) for more details. +See the [documentation](https://lodash.com/docs#assignInWith) or [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash.assigninwith) for more details. diff --git a/lodash.assigninwith/index.js b/lodash.assigninwith/index.js index efb03c20c..a6c436aa9 100644 --- a/lodash.assigninwith/index.js +++ b/lodash.assigninwith/index.js @@ -1,5 +1,5 @@ /** - * lodash 4.0.1 (Custom Build) + * lodash 4.0.2 (Custom Build) * Build: `lodash modularize exports="npm" -o ./` * Copyright 2012-2016 The Dojo Foundation * Based on Underscore.js 1.8.3 @@ -34,7 +34,7 @@ function isIndex(value, length) { } /** Used for built-in method references. */ -var objectProto = global.Object.prototype; +var objectProto = Object.prototype; /** Used to check objects for own properties. */ var hasOwnProperty = objectProto.hasOwnProperty; @@ -146,7 +146,7 @@ function createAssigner(assigner) { var getLength = baseProperty('length'); /** - * Checks if the provided arguments are from an iteratee call. + * Checks if the given arguments are from an iteratee call. * * @private * @param {*} value The potential iteratee value argument. diff --git a/lodash.assigninwith/package.json b/lodash.assigninwith/package.json index da8ec2353..46020ae5e 100644 --- a/lodash.assigninwith/package.json +++ b/lodash.assigninwith/package.json @@ -1,11 +1,11 @@ { "name": "lodash.assigninwith", - "version": "4.0.1", + "version": "4.0.2", "description": "The lodash method `_.assignInWith` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", "license": "MIT", - "keywords": "lodash, lodash-modularized, stdlib, util, assigninwith", + "keywords": "lodash-modularized, assigninwith", "author": "John-David Dalton (http://allyoucanleet.com/)", "contributors": [ "John-David Dalton (http://allyoucanleet.com/)", diff --git a/lodash.assignwith/README.md b/lodash.assignwith/README.md index b89acc2c7..106ddb6e5 100644 --- a/lodash.assignwith/README.md +++ b/lodash.assignwith/README.md @@ -1,4 +1,4 @@ -# lodash.assignwith v4.0.1 +# lodash.assignwith v4.0.2 The [lodash](https://lodash.com/) method `_.assignWith` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var assignWith = require('lodash.assignwith'); ``` -See the [documentation](https://lodash.com/docs#assignWith) or [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash.assignwith) for more details. +See the [documentation](https://lodash.com/docs#assignWith) or [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash.assignwith) for more details. diff --git a/lodash.assignwith/index.js b/lodash.assignwith/index.js index c7b4b7932..cfc032f5b 100644 --- a/lodash.assignwith/index.js +++ b/lodash.assignwith/index.js @@ -1,5 +1,5 @@ /** - * lodash 4.0.1 (Custom Build) + * lodash 4.0.2 (Custom Build) * Build: `lodash modularize exports="npm" -o ./` * Copyright 2012-2016 The Dojo Foundation * Based on Underscore.js 1.8.3 @@ -34,7 +34,7 @@ function isIndex(value, length) { } /** Used for built-in method references. */ -var objectProto = global.Object.prototype; +var objectProto = Object.prototype; /** Used to check objects for own properties. */ var hasOwnProperty = objectProto.hasOwnProperty; @@ -146,7 +146,7 @@ function createAssigner(assigner) { var getLength = baseProperty('length'); /** - * Checks if the provided arguments are from an iteratee call. + * Checks if the given arguments are from an iteratee call. * * @private * @param {*} value The potential iteratee value argument. diff --git a/lodash.assignwith/package.json b/lodash.assignwith/package.json index d4fcff7b6..bfadd7cb8 100644 --- a/lodash.assignwith/package.json +++ b/lodash.assignwith/package.json @@ -1,11 +1,11 @@ { "name": "lodash.assignwith", - "version": "4.0.1", + "version": "4.0.2", "description": "The lodash method `_.assignWith` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", "license": "MIT", - "keywords": "lodash, lodash-modularized, stdlib, util, assignwith", + "keywords": "lodash-modularized, assignwith", "author": "John-David Dalton (http://allyoucanleet.com/)", "contributors": [ "John-David Dalton (http://allyoucanleet.com/)", diff --git a/lodash.before/LICENSE b/lodash.before/LICENSE index b054ca5a3..e0c69d560 100644 --- a/lodash.before/LICENSE +++ b/lodash.before/LICENSE @@ -1,7 +1,17 @@ -Copyright 2012-2016 The Dojo Foundation -Based on Underscore.js, copyright 2009-2016 Jeremy Ashkenas, +Copyright jQuery Foundation and other contributors + +Based on Underscore.js, copyright Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors +This software consists of voluntary contributions made by many +individuals. For exact contribution history, see the revision history +available at https://github.com/lodash/lodash + +The following license applies to all parts of this software except as +documented below: + +==== + Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including @@ -20,3 +30,18 @@ NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + +==== + +Copyright and related rights for sample code are waived via CC0. Sample +code is defined as all source code displayed within the prose of the +documentation. + +CC0: http://creativecommons.org/publicdomain/zero/1.0/ + +==== + +Files located in the node_modules and vendor directories are externally +maintained libraries used by this software which have their own +licenses; we recommend you read them, as their terms may differ from the +terms above. diff --git a/lodash.before/README.md b/lodash.before/README.md index 44c9a70c3..488ad90e2 100644 --- a/lodash.before/README.md +++ b/lodash.before/README.md @@ -1,4 +1,4 @@ -# lodash.before v4.0.1 +# lodash.before v4.0.2 The [lodash](https://lodash.com/) method `_.before` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var before = require('lodash.before'); ``` -See the [documentation](https://lodash.com/docs#before) or [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash.before) for more details. +See the [documentation](https://lodash.com/docs#before) or [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash.before) for more details. diff --git a/lodash.before/index.js b/lodash.before/index.js index a6f86befd..767793478 100644 --- a/lodash.before/index.js +++ b/lodash.before/index.js @@ -1,10 +1,10 @@ /** - * lodash 4.0.1 (Custom Build) + * lodash 4.0.2 (Custom Build) * Build: `lodash modularize exports="npm" -o ./` - * Copyright 2012-2016 The Dojo Foundation + * Copyright jQuery Foundation and other contributors + * Released under MIT license * Based on Underscore.js 1.8.3 - * Copyright 2009-2016 Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors - * Available under MIT license + * Copyright Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors */ /** Used as the `TypeError` message for "Functions" methods. */ @@ -17,7 +17,8 @@ var INFINITY = 1 / 0, /** `Object#toString` result references. */ var funcTag = '[object Function]', - genTag = '[object GeneratorFunction]'; + genTag = '[object GeneratorFunction]', + symbolTag = '[object Symbol]'; /** Used to match leading and trailing whitespace. */ var reTrim = /^\s+|\s+$/g; @@ -38,7 +39,8 @@ var freeParseInt = parseInt; var objectProto = Object.prototype; /** - * Used to resolve the [`toStringTag`](http://ecma-international.org/ecma-262/6.0/#sec-object.prototype.tostring) + * Used to resolve the + * [`toStringTag`](http://ecma-international.org/ecma-262/6.0/#sec-object.prototype.tostring) * of values. */ var objectToString = objectProto.toString; @@ -50,6 +52,7 @@ var objectToString = objectProto.toString; * * @static * @memberOf _ + * @since 3.0.0 * @category Function * @param {number} n The number of calls at which `func` is no longer invoked. * @param {Function} func The function to restrict. @@ -81,9 +84,11 @@ function before(n, func) { * * @static * @memberOf _ + * @since 0.1.0 * @category Lang * @param {*} value The value to check. - * @returns {boolean} Returns `true` if `value` is correctly classified, else `false`. + * @returns {boolean} Returns `true` if `value` is correctly classified, + * else `false`. * @example * * _.isFunction(_); @@ -101,11 +106,13 @@ function isFunction(value) { } /** - * Checks if `value` is the [language type](https://es5.github.io/#x8) of `Object`. - * (e.g. arrays, functions, objects, regexes, `new Number(0)`, and `new String('')`) + * Checks if `value` is the + * [language type](http://www.ecma-international.org/ecma-262/6.0/#sec-ecmascript-language-types) + * of `Object`. (e.g. arrays, functions, objects, regexes, `new Number(0)`, and `new String('')`) * * @static * @memberOf _ + * @since 0.1.0 * @category Lang * @param {*} value The value to check. * @returns {boolean} Returns `true` if `value` is an object, else `false`. @@ -129,12 +136,65 @@ function isObject(value) { } /** - * Converts `value` to an integer. - * - * **Note:** This function is loosely based on [`ToInteger`](http://www.ecma-international.org/ecma-262/6.0/#sec-tointeger). + * Checks if `value` is object-like. A value is object-like if it's not `null` + * and has a `typeof` result of "object". * * @static * @memberOf _ + * @since 4.0.0 + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is object-like, else `false`. + * @example + * + * _.isObjectLike({}); + * // => true + * + * _.isObjectLike([1, 2, 3]); + * // => true + * + * _.isObjectLike(_.noop); + * // => false + * + * _.isObjectLike(null); + * // => false + */ +function isObjectLike(value) { + return !!value && typeof value == 'object'; +} + +/** + * Checks if `value` is classified as a `Symbol` primitive or object. + * + * @static + * @memberOf _ + * @since 4.0.0 + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is correctly classified, + * else `false`. + * @example + * + * _.isSymbol(Symbol.iterator); + * // => true + * + * _.isSymbol('abc'); + * // => false + */ +function isSymbol(value) { + return typeof value == 'symbol' || + (isObjectLike(value) && objectToString.call(value) == symbolTag); +} + +/** + * Converts `value` to an integer. + * + * **Note:** This function is loosely based on + * [`ToInteger`](http://www.ecma-international.org/ecma-262/6.0/#sec-tointeger). + * + * @static + * @memberOf _ + * @since 4.0.0 * @category Lang * @param {*} value The value to convert. * @returns {number} Returns the converted integer. @@ -170,6 +230,7 @@ function toInteger(value) { * * @static * @memberOf _ + * @since 4.0.0 * @category Lang * @param {*} value The value to process. * @returns {number} Returns the number. @@ -188,6 +249,12 @@ function toInteger(value) { * // => 3 */ function toNumber(value) { + if (typeof value == 'number') { + return value; + } + if (isSymbol(value)) { + return NAN; + } if (isObject(value)) { var other = isFunction(value.valueOf) ? value.valueOf() : value; value = isObject(other) ? (other + '') : other; diff --git a/lodash.before/package.json b/lodash.before/package.json index 7f95a7f24..0265318d7 100644 --- a/lodash.before/package.json +++ b/lodash.before/package.json @@ -1,6 +1,6 @@ { "name": "lodash.before", - "version": "4.0.1", + "version": "4.0.2", "description": "The lodash method `_.before` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", @@ -9,7 +9,7 @@ "author": "John-David Dalton (http://allyoucanleet.com/)", "contributors": [ "John-David Dalton (http://allyoucanleet.com/)", - "Blaine Bublitz (https://github.com/phated)", + "Blaine Bublitz (https://github.com/phated)", "Mathias Bynens (https://mathiasbynens.be/)" ], "repository": "lodash/lodash", diff --git a/lodash.capitalize/README.md b/lodash.capitalize/README.md index c0dfddff0..7a94d219e 100644 --- a/lodash.capitalize/README.md +++ b/lodash.capitalize/README.md @@ -1,4 +1,4 @@ -# lodash.capitalize v4.0.1 +# lodash.capitalize v4.0.2 The [lodash](https://lodash.com/) method `_.capitalize` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var capitalize = require('lodash.capitalize'); ``` -See the [documentation](https://lodash.com/docs#capitalize) or [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash.capitalize) for more details. +See the [documentation](https://lodash.com/docs#capitalize) or [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash.capitalize) for more details. diff --git a/lodash.capitalize/index.js b/lodash.capitalize/index.js index 45e0fa9ca..546394c12 100644 --- a/lodash.capitalize/index.js +++ b/lodash.capitalize/index.js @@ -1,5 +1,5 @@ /** - * lodash 4.0.0 (Custom Build) + * lodash 4.0.2 (Custom Build) * Build: `lodash modularize exports="npm" -o ./` * Copyright 2012-2016 The Dojo Foundation * Based on Underscore.js 1.8.3 @@ -24,11 +24,11 @@ var objectProto = global.Object.prototype; var objectToString = objectProto.toString; /** Built-in value references. */ -var _Symbol = global.Symbol; +var Symbol = global.Symbol; /** Used to convert symbols to primitives and strings. */ -var symbolProto = _Symbol ? _Symbol.prototype : undefined, - symbolToString = _Symbol ? symbolProto.toString : undefined; +var symbolProto = Symbol ? Symbol.prototype : undefined, + symbolToString = Symbol ? symbolProto.toString : undefined; /** * Checks if `value` is object-like. A value is object-like if it's not `null` @@ -107,7 +107,7 @@ function toString(value) { return ''; } if (isSymbol(value)) { - return _Symbol ? symbolToString.call(value) : ''; + return Symbol ? symbolToString.call(value) : ''; } var result = (value + ''); return (result == '0' && (1 / value) == -INFINITY) ? '-0' : result; diff --git a/lodash.capitalize/package.json b/lodash.capitalize/package.json index 6fda114d3..6d245ae96 100644 --- a/lodash.capitalize/package.json +++ b/lodash.capitalize/package.json @@ -1,6 +1,6 @@ { "name": "lodash.capitalize", - "version": "4.0.1", + "version": "4.0.2", "description": "The lodash method `_.capitalize` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", diff --git a/lodash.ceil/README.md b/lodash.ceil/README.md index 250c2c23a..8339d6ee0 100644 --- a/lodash.ceil/README.md +++ b/lodash.ceil/README.md @@ -1,4 +1,4 @@ -# lodash.ceil v4.0.1 +# lodash.ceil v4.0.2 The [lodash](https://lodash.com/) method `_.ceil` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var ceil = require('lodash.ceil'); ``` -See the [documentation](https://lodash.com/docs#ceil) or [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash.ceil) for more details. +See the [documentation](https://lodash.com/docs#ceil) or [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash.ceil) for more details. diff --git a/lodash.ceil/index.js b/lodash.ceil/index.js index f6871f732..bf840fed7 100644 --- a/lodash.ceil/index.js +++ b/lodash.ceil/index.js @@ -1,5 +1,5 @@ /** - * lodash 4.0.1 (Custom Build) + * lodash (Custom Build) * Build: `lodash modularize exports="npm" -o ./` * Copyright jQuery Foundation and other contributors * Released under MIT license @@ -175,6 +175,41 @@ function isSymbol(value) { (isObjectLike(value) && objectToString.call(value) == symbolTag); } +/** + * Converts `value` to a finite number. + * + * @static + * @memberOf _ + * @since 4.12.0 + * @category Lang + * @param {*} value The value to convert. + * @returns {number} Returns the converted number. + * @example + * + * _.toFinite(3.2); + * // => 3.2 + * + * _.toFinite(Number.MIN_VALUE); + * // => 5e-324 + * + * _.toFinite(Infinity); + * // => 1.7976931348623157e+308 + * + * _.toFinite('3.2'); + * // => 3.2 + */ +function toFinite(value) { + if (!value) { + return value === 0 ? value : 0; + } + value = toNumber(value); + if (value === INFINITY || value === -INFINITY) { + var sign = (value < 0 ? -1 : 1); + return sign * MAX_INTEGER; + } + return value === value ? value : 0; +} + /** * Converts `value` to an integer. * @@ -189,7 +224,7 @@ function isSymbol(value) { * @returns {number} Returns the converted integer. * @example * - * _.toInteger(3); + * _.toInteger(3.2); * // => 3 * * _.toInteger(Number.MIN_VALUE); @@ -198,20 +233,14 @@ function isSymbol(value) { * _.toInteger(Infinity); * // => 1.7976931348623157e+308 * - * _.toInteger('3'); + * _.toInteger('3.2'); * // => 3 */ function toInteger(value) { - if (!value) { - return value === 0 ? value : 0; - } - value = toNumber(value); - if (value === INFINITY || value === -INFINITY) { - var sign = (value < 0 ? -1 : 1); - return sign * MAX_INTEGER; - } - var remainder = value % 1; - return value === value ? (remainder ? value - remainder : value) : 0; + var result = toFinite(value), + remainder = result % 1; + + return result === result ? (remainder ? result - remainder : result) : 0; } /** @@ -225,8 +254,8 @@ function toInteger(value) { * @returns {number} Returns the number. * @example * - * _.toNumber(3); - * // => 3 + * _.toNumber(3.2); + * // => 3.2 * * _.toNumber(Number.MIN_VALUE); * // => 5e-324 @@ -234,8 +263,8 @@ function toInteger(value) { * _.toNumber(Infinity); * // => Infinity * - * _.toNumber('3'); - * // => 3 + * _.toNumber('3.2'); + * // => 3.2 */ function toNumber(value) { if (typeof value == 'number') { diff --git a/lodash.ceil/package.json b/lodash.ceil/package.json index 9abc0e85d..308cc5316 100644 --- a/lodash.ceil/package.json +++ b/lodash.ceil/package.json @@ -1,6 +1,6 @@ { "name": "lodash.ceil", - "version": "4.0.1", + "version": "4.0.2", "description": "The lodash method `_.ceil` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", diff --git a/lodash.chunk/LICENSE b/lodash.chunk/LICENSE index b054ca5a3..bcbe13d67 100644 --- a/lodash.chunk/LICENSE +++ b/lodash.chunk/LICENSE @@ -1,22 +1,23 @@ +The MIT License (MIT) + Copyright 2012-2016 The Dojo Foundation Based on Underscore.js, copyright 2009-2016 Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors -Permission is hereby granted, free of charge, to any person obtaining -a copy of this software and associated documentation files (the -"Software"), to deal in the Software without restriction, including -without limitation the rights to use, copy, modify, merge, publish, -distribute, sublicense, and/or sell copies of the Software, and to -permit persons to whom the Software is furnished to do so, subject to -the following conditions: +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: -The above copyright notice and this permission notice shall be -included in all copies or substantial portions of the Software. +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, -EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND -NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE -LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION -OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION -WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. diff --git a/lodash.chunk/README.md b/lodash.chunk/README.md index 9ea756d53..6f507ab3e 100644 --- a/lodash.chunk/README.md +++ b/lodash.chunk/README.md @@ -1,4 +1,4 @@ -# lodash.chunk v4.0.1 +# lodash.chunk v4.0.2 The [lodash](https://lodash.com/) method `_.chunk` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var chunk = require('lodash.chunk'); ``` -See the [documentation](https://lodash.com/docs#chunk) or [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash.chunk) for more details. +See the [documentation](https://lodash.com/docs#chunk) or [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash.chunk) for more details. diff --git a/lodash.chunk/index.js b/lodash.chunk/index.js index a53b07667..76703ed28 100644 --- a/lodash.chunk/index.js +++ b/lodash.chunk/index.js @@ -1,5 +1,5 @@ /** - * lodash 4.0.1 (Custom Build) + * lodash 4.0.2 (Custom Build) * Build: `lodash modularize exports="npm" -o ./` * Copyright 2012-2016 The Dojo Foundation * Based on Underscore.js 1.8.3 @@ -72,11 +72,11 @@ function chunk(array, size) { return []; } var index = 0, - resIndex = -1, + resIndex = 0, result = Array(nativeCeil(length / size)); while (index < length) { - result[++resIndex] = baseSlice(array, index, (index += size)); + result[resIndex++] = baseSlice(array, index, (index += size)); } return result; } @@ -99,8 +99,8 @@ function chunk(array, size) { */ function isFunction(value) { // The use of `Object#toString` avoids issues with the `typeof` operator - // in Safari 8 which returns 'object' for typed array constructors, and - // PhantomJS 1.9 which returns 'function' for `NodeList` instances. + // in Safari 8 which returns 'object' for typed array and weak map constructors, + // and PhantomJS 1.9 which returns 'function' for `NodeList` instances. var tag = isObject(value) ? objectToString.call(value) : ''; return tag == funcTag || tag == genTag; } diff --git a/lodash.chunk/package.json b/lodash.chunk/package.json index 693d28c71..54ff6e4fa 100644 --- a/lodash.chunk/package.json +++ b/lodash.chunk/package.json @@ -1,6 +1,6 @@ { "name": "lodash.chunk", - "version": "4.0.1", + "version": "4.0.2", "description": "The lodash method `_.chunk` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", @@ -9,7 +9,7 @@ "author": "John-David Dalton (http://allyoucanleet.com/)", "contributors": [ "John-David Dalton (http://allyoucanleet.com/)", - "Blaine Bublitz (https://github.com/phated)", + "Blaine Bublitz (https://github.com/phated)", "Mathias Bynens (https://mathiasbynens.be/)" ], "repository": "lodash/lodash", diff --git a/lodash.clamp/LICENSE b/lodash.clamp/LICENSE index b054ca5a3..e0c69d560 100644 --- a/lodash.clamp/LICENSE +++ b/lodash.clamp/LICENSE @@ -1,7 +1,17 @@ -Copyright 2012-2016 The Dojo Foundation -Based on Underscore.js, copyright 2009-2016 Jeremy Ashkenas, +Copyright jQuery Foundation and other contributors + +Based on Underscore.js, copyright Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors +This software consists of voluntary contributions made by many +individuals. For exact contribution history, see the revision history +available at https://github.com/lodash/lodash + +The following license applies to all parts of this software except as +documented below: + +==== + Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including @@ -20,3 +30,18 @@ NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + +==== + +Copyright and related rights for sample code are waived via CC0. Sample +code is defined as all source code displayed within the prose of the +documentation. + +CC0: http://creativecommons.org/publicdomain/zero/1.0/ + +==== + +Files located in the node_modules and vendor directories are externally +maintained libraries used by this software which have their own +licenses; we recommend you read them, as their terms may differ from the +terms above. diff --git a/lodash.clamp/README.md b/lodash.clamp/README.md index 7d1cf1c6b..ef52ed756 100644 --- a/lodash.clamp/README.md +++ b/lodash.clamp/README.md @@ -1,4 +1,4 @@ -# lodash.clamp v4.0.1 +# lodash.clamp v4.0.2 The [lodash](https://lodash.com/) method `_.clamp` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var clamp = require('lodash.clamp'); ``` -See the [documentation](https://lodash.com/docs#clamp) or [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash.clamp) for more details. +See the [documentation](https://lodash.com/docs#clamp) or [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash.clamp) for more details. diff --git a/lodash.clamp/index.js b/lodash.clamp/index.js index ab6339d8d..b8879d8ca 100644 --- a/lodash.clamp/index.js +++ b/lodash.clamp/index.js @@ -1,10 +1,10 @@ /** - * lodash 4.0.1 (Custom Build) + * lodash (Custom Build) * Build: `lodash modularize exports="npm" -o ./` - * Copyright 2012-2016 The Dojo Foundation + * Copyright jQuery Foundation and other contributors + * Released under MIT license * Based on Underscore.js 1.8.3 - * Copyright 2009-2016 Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors - * Available under MIT license + * Copyright Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors */ /** Used as references for various `Number` constants. */ @@ -12,7 +12,8 @@ var NAN = 0 / 0; /** `Object#toString` result references. */ var funcTag = '[object Function]', - genTag = '[object GeneratorFunction]'; + genTag = '[object GeneratorFunction]', + symbolTag = '[object Symbol]'; /** Used to match leading and trailing whitespace. */ var reTrim = /^\s+|\s+$/g; @@ -33,13 +34,14 @@ var freeParseInt = parseInt; var objectProto = Object.prototype; /** - * Used to resolve the [`toStringTag`](http://ecma-international.org/ecma-262/6.0/#sec-object.prototype.tostring) + * Used to resolve the + * [`toStringTag`](http://ecma-international.org/ecma-262/6.0/#sec-object.prototype.tostring) * of values. */ var objectToString = objectProto.toString; /** - * The base implementation of `_.clamp` which doesn't coerce arguments to numbers. + * The base implementation of `_.clamp` which doesn't coerce arguments. * * @private * @param {number} number The number to clamp. @@ -64,9 +66,10 @@ function baseClamp(number, lower, upper) { * * @static * @memberOf _ + * @since 0.1.0 * @category Lang * @param {*} value The value to check. - * @returns {boolean} Returns `true` if `value` is correctly classified, else `false`. + * @returns {boolean} Returns `true` if `value` is a function, else `false`. * @example * * _.isFunction(_); @@ -84,11 +87,13 @@ function isFunction(value) { } /** - * Checks if `value` is the [language type](https://es5.github.io/#x8) of `Object`. - * (e.g. arrays, functions, objects, regexes, `new Number(0)`, and `new String('')`) + * Checks if `value` is the + * [language type](http://www.ecma-international.org/ecma-262/6.0/#sec-ecmascript-language-types) + * of `Object`. (e.g. arrays, functions, objects, regexes, `new Number(0)`, and `new String('')`) * * @static * @memberOf _ + * @since 0.1.0 * @category Lang * @param {*} value The value to check. * @returns {boolean} Returns `true` if `value` is an object, else `false`. @@ -111,18 +116,69 @@ function isObject(value) { return !!value && (type == 'object' || type == 'function'); } +/** + * Checks if `value` is object-like. A value is object-like if it's not `null` + * and has a `typeof` result of "object". + * + * @static + * @memberOf _ + * @since 4.0.0 + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is object-like, else `false`. + * @example + * + * _.isObjectLike({}); + * // => true + * + * _.isObjectLike([1, 2, 3]); + * // => true + * + * _.isObjectLike(_.noop); + * // => false + * + * _.isObjectLike(null); + * // => false + */ +function isObjectLike(value) { + return !!value && typeof value == 'object'; +} + +/** + * Checks if `value` is classified as a `Symbol` primitive or object. + * + * @static + * @memberOf _ + * @since 4.0.0 + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is a symbol, else `false`. + * @example + * + * _.isSymbol(Symbol.iterator); + * // => true + * + * _.isSymbol('abc'); + * // => false + */ +function isSymbol(value) { + return typeof value == 'symbol' || + (isObjectLike(value) && objectToString.call(value) == symbolTag); +} + /** * Converts `value` to a number. * * @static * @memberOf _ + * @since 4.0.0 * @category Lang * @param {*} value The value to process. * @returns {number} Returns the number. * @example * - * _.toNumber(3); - * // => 3 + * _.toNumber(3.2); + * // => 3.2 * * _.toNumber(Number.MIN_VALUE); * // => 5e-324 @@ -130,10 +186,16 @@ function isObject(value) { * _.toNumber(Infinity); * // => Infinity * - * _.toNumber('3'); - * // => 3 + * _.toNumber('3.2'); + * // => 3.2 */ function toNumber(value) { + if (typeof value == 'number') { + return value; + } + if (isSymbol(value)) { + return NAN; + } if (isObject(value)) { var other = isFunction(value.valueOf) ? value.valueOf() : value; value = isObject(other) ? (other + '') : other; @@ -153,6 +215,7 @@ function toNumber(value) { * * @static * @memberOf _ + * @since 4.0.0 * @category Number * @param {number} number The number to clamp. * @param {number} [lower] The lower bound. diff --git a/lodash.clamp/package.json b/lodash.clamp/package.json index 84640f3ee..f77d22e03 100644 --- a/lodash.clamp/package.json +++ b/lodash.clamp/package.json @@ -1,6 +1,6 @@ { "name": "lodash.clamp", - "version": "4.0.1", + "version": "4.0.2", "description": "The lodash method `_.clamp` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", @@ -9,7 +9,7 @@ "author": "John-David Dalton (http://allyoucanleet.com/)", "contributors": [ "John-David Dalton (http://allyoucanleet.com/)", - "Blaine Bublitz (https://github.com/phated)", + "Blaine Bublitz (https://github.com/phated)", "Mathias Bynens (https://mathiasbynens.be/)" ], "repository": "lodash/lodash", diff --git a/lodash.clone/README.md b/lodash.clone/README.md index ac63e1fd5..80f8818f8 100644 --- a/lodash.clone/README.md +++ b/lodash.clone/README.md @@ -1,4 +1,4 @@ -# lodash.clone v4.0.1 +# lodash.clone v4.0.2 The [lodash](https://lodash.com/) method `_.clone` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var clone = require('lodash.clone'); ``` -See the [documentation](https://lodash.com/docs#clone) or [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash.clone) for more details. +See the [documentation](https://lodash.com/docs#clone) or [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash.clone) for more details. diff --git a/lodash.clone/index.js b/lodash.clone/index.js index c2da9a3b7..6d634162d 100644 --- a/lodash.clone/index.js +++ b/lodash.clone/index.js @@ -1,5 +1,5 @@ /** - * lodash 4.0.0 (Custom Build) + * lodash 4.0.2 (Custom Build) * Build: `lodash modularize exports="npm" -o ./` * Copyright 2012-2016 The Dojo Foundation * Based on Underscore.js 1.8.3 @@ -98,14 +98,14 @@ function addSetEntry(set, value) { * @param {Array} array The array to iterate over. * @param {Function} iteratee The function invoked per iteration. * @param {*} [accumulator] The initial value. - * @param {boolean} [initFromArray] Specify using the first element of `array` as the initial value. + * @param {boolean} [initAccum] Specify using the first element of `array` as the initial value. * @returns {*} Returns the accumulated value. */ -function arrayReduce(array, iteratee, accumulator, initFromArray) { +function arrayReduce(array, iteratee, accumulator, initAccum) { var index = -1, length = array.length; - if (initFromArray && length) { + if (initAccum && length) { accumulator = array[++index]; } while (++index < length) { @@ -189,7 +189,7 @@ var reIsNative = RegExp('^' + ); /** Built-in value references. */ -var _Symbol = global.Symbol, +var Symbol = global.Symbol, Uint8Array = global.Uint8Array, getOwnPropertySymbols = Object.getOwnPropertySymbols; @@ -202,8 +202,8 @@ var mapCtorString = Map ? funcToString.call(Map) : '', setCtorString = Set ? funcToString.call(Set) : ''; /** Used to convert symbols to primitives and strings. */ -var symbolProto = _Symbol ? _Symbol.prototype : undefined, - symbolValueOf = _Symbol ? symbolProto.valueOf : undefined; +var symbolProto = Symbol ? Symbol.prototype : undefined, + symbolValueOf = Symbol ? symbolProto.valueOf : undefined; /** * Assigns `value` to `key` of `object` if the existing value is not equivalent @@ -395,7 +395,7 @@ function cloneSet(set) { * @returns {Object} Returns the cloned symbol object. */ function cloneSymbol(symbol) { - return _Symbol ? Object(symbolValueOf.call(symbol)) : {}; + return Symbol ? Object(symbolValueOf.call(symbol)) : {}; } /** diff --git a/lodash.clone/package.json b/lodash.clone/package.json index 095da9dff..51530816b 100644 --- a/lodash.clone/package.json +++ b/lodash.clone/package.json @@ -1,6 +1,6 @@ { "name": "lodash.clone", - "version": "4.0.1", + "version": "4.0.2", "description": "The lodash method `_.clone` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", diff --git a/lodash.clonedeep/README.md b/lodash.clonedeep/README.md index 65176db36..63dbb3fbb 100644 --- a/lodash.clonedeep/README.md +++ b/lodash.clonedeep/README.md @@ -1,4 +1,4 @@ -# lodash.clonedeep v4.0.1 +# lodash.clonedeep v4.0.2 The [lodash](https://lodash.com/) method `_.cloneDeep` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var cloneDeep = require('lodash.clonedeep'); ``` -See the [documentation](https://lodash.com/docs#cloneDeep) or [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash.clonedeep) for more details. +See the [documentation](https://lodash.com/docs#cloneDeep) or [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash.clonedeep) for more details. diff --git a/lodash.clonedeep/index.js b/lodash.clonedeep/index.js index c9082a6a5..c50c62dcd 100644 --- a/lodash.clonedeep/index.js +++ b/lodash.clonedeep/index.js @@ -1,5 +1,5 @@ /** - * lodash 4.0.0 (Custom Build) + * lodash 4.0.2 (Custom Build) * Build: `lodash modularize exports="npm" -o ./` * Copyright 2012-2016 The Dojo Foundation * Based on Underscore.js 1.8.3 @@ -98,14 +98,14 @@ function addSetEntry(set, value) { * @param {Array} array The array to iterate over. * @param {Function} iteratee The function invoked per iteration. * @param {*} [accumulator] The initial value. - * @param {boolean} [initFromArray] Specify using the first element of `array` as the initial value. + * @param {boolean} [initAccum] Specify using the first element of `array` as the initial value. * @returns {*} Returns the accumulated value. */ -function arrayReduce(array, iteratee, accumulator, initFromArray) { +function arrayReduce(array, iteratee, accumulator, initAccum) { var index = -1, length = array.length; - if (initFromArray && length) { + if (initAccum && length) { accumulator = array[++index]; } while (++index < length) { @@ -189,7 +189,7 @@ var reIsNative = RegExp('^' + ); /** Built-in value references. */ -var _Symbol = global.Symbol, +var Symbol = global.Symbol, Uint8Array = global.Uint8Array, getOwnPropertySymbols = Object.getOwnPropertySymbols; @@ -202,8 +202,8 @@ var mapCtorString = Map ? funcToString.call(Map) : '', setCtorString = Set ? funcToString.call(Set) : ''; /** Used to convert symbols to primitives and strings. */ -var symbolProto = _Symbol ? _Symbol.prototype : undefined, - symbolValueOf = _Symbol ? symbolProto.valueOf : undefined; +var symbolProto = Symbol ? Symbol.prototype : undefined, + symbolValueOf = Symbol ? symbolProto.valueOf : undefined; /** * Assigns `value` to `key` of `object` if the existing value is not equivalent @@ -395,7 +395,7 @@ function cloneSet(set) { * @returns {Object} Returns the cloned symbol object. */ function cloneSymbol(symbol) { - return _Symbol ? Object(symbolValueOf.call(symbol)) : {}; + return Symbol ? Object(symbolValueOf.call(symbol)) : {}; } /** diff --git a/lodash.clonedeep/package.json b/lodash.clonedeep/package.json index 54ce65258..82688f78c 100644 --- a/lodash.clonedeep/package.json +++ b/lodash.clonedeep/package.json @@ -1,6 +1,6 @@ { "name": "lodash.clonedeep", - "version": "4.0.1", + "version": "4.0.2", "description": "The lodash method `_.cloneDeep` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", diff --git a/lodash.clonedeepwith/README.md b/lodash.clonedeepwith/README.md index fe7a5924b..1ca65ab79 100644 --- a/lodash.clonedeepwith/README.md +++ b/lodash.clonedeepwith/README.md @@ -1,4 +1,4 @@ -# lodash.clonedeepwith v4.0.1 +# lodash.clonedeepwith v4.0.2 The [lodash](https://lodash.com/) method `_.cloneDeepWith` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var cloneDeepWith = require('lodash.clonedeepwith'); ``` -See the [documentation](https://lodash.com/docs#cloneDeepWith) or [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash.clonedeepwith) for more details. +See the [documentation](https://lodash.com/docs#cloneDeepWith) or [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash.clonedeepwith) for more details. diff --git a/lodash.clonedeepwith/index.js b/lodash.clonedeepwith/index.js index 8aa4154f0..c19db250b 100644 --- a/lodash.clonedeepwith/index.js +++ b/lodash.clonedeepwith/index.js @@ -1,5 +1,5 @@ /** - * lodash 4.0.0 (Custom Build) + * lodash 4.0.2 (Custom Build) * Build: `lodash modularize exports="npm" -o ./` * Copyright 2012-2016 The Dojo Foundation * Based on Underscore.js 1.8.3 @@ -98,14 +98,14 @@ function addSetEntry(set, value) { * @param {Array} array The array to iterate over. * @param {Function} iteratee The function invoked per iteration. * @param {*} [accumulator] The initial value. - * @param {boolean} [initFromArray] Specify using the first element of `array` as the initial value. + * @param {boolean} [initAccum] Specify using the first element of `array` as the initial value. * @returns {*} Returns the accumulated value. */ -function arrayReduce(array, iteratee, accumulator, initFromArray) { +function arrayReduce(array, iteratee, accumulator, initAccum) { var index = -1, length = array.length; - if (initFromArray && length) { + if (initAccum && length) { accumulator = array[++index]; } while (++index < length) { @@ -189,7 +189,7 @@ var reIsNative = RegExp('^' + ); /** Built-in value references. */ -var _Symbol = global.Symbol, +var Symbol = global.Symbol, Uint8Array = global.Uint8Array, getOwnPropertySymbols = Object.getOwnPropertySymbols; @@ -202,8 +202,8 @@ var mapCtorString = Map ? funcToString.call(Map) : '', setCtorString = Set ? funcToString.call(Set) : ''; /** Used to convert symbols to primitives and strings. */ -var symbolProto = _Symbol ? _Symbol.prototype : undefined, - symbolValueOf = _Symbol ? symbolProto.valueOf : undefined; +var symbolProto = Symbol ? Symbol.prototype : undefined, + symbolValueOf = Symbol ? symbolProto.valueOf : undefined; /** * Assigns `value` to `key` of `object` if the existing value is not equivalent @@ -395,7 +395,7 @@ function cloneSet(set) { * @returns {Object} Returns the cloned symbol object. */ function cloneSymbol(symbol) { - return _Symbol ? Object(symbolValueOf.call(symbol)) : {}; + return Symbol ? Object(symbolValueOf.call(symbol)) : {}; } /** @@ -630,7 +630,7 @@ function initCloneByTag(object, tag, isDeep) { * } * } * - * var el = _.cloneDeep(document.body, customizer); + * var el = _.cloneDeepWith(document.body, customizer); * * console.log(el === document.body); * // => false diff --git a/lodash.clonedeepwith/package.json b/lodash.clonedeepwith/package.json index 13ba36a8d..1835069bd 100644 --- a/lodash.clonedeepwith/package.json +++ b/lodash.clonedeepwith/package.json @@ -1,6 +1,6 @@ { "name": "lodash.clonedeepwith", - "version": "4.0.1", + "version": "4.0.2", "description": "The lodash method `_.cloneDeepWith` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", diff --git a/lodash.clonewith/README.md b/lodash.clonewith/README.md index 0040c8e2f..e0d0dd404 100644 --- a/lodash.clonewith/README.md +++ b/lodash.clonewith/README.md @@ -1,4 +1,4 @@ -# lodash.clonewith v4.0.1 +# lodash.clonewith v4.0.2 The [lodash](https://lodash.com/) method `_.cloneWith` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var cloneWith = require('lodash.clonewith'); ``` -See the [documentation](https://lodash.com/docs#cloneWith) or [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash.clonewith) for more details. +See the [documentation](https://lodash.com/docs#cloneWith) or [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash.clonewith) for more details. diff --git a/lodash.clonewith/index.js b/lodash.clonewith/index.js index 41b5376cc..a01d0c76d 100644 --- a/lodash.clonewith/index.js +++ b/lodash.clonewith/index.js @@ -1,5 +1,5 @@ /** - * lodash 4.0.0 (Custom Build) + * lodash 4.0.2 (Custom Build) * Build: `lodash modularize exports="npm" -o ./` * Copyright 2012-2016 The Dojo Foundation * Based on Underscore.js 1.8.3 @@ -98,14 +98,14 @@ function addSetEntry(set, value) { * @param {Array} array The array to iterate over. * @param {Function} iteratee The function invoked per iteration. * @param {*} [accumulator] The initial value. - * @param {boolean} [initFromArray] Specify using the first element of `array` as the initial value. + * @param {boolean} [initAccum] Specify using the first element of `array` as the initial value. * @returns {*} Returns the accumulated value. */ -function arrayReduce(array, iteratee, accumulator, initFromArray) { +function arrayReduce(array, iteratee, accumulator, initAccum) { var index = -1, length = array.length; - if (initFromArray && length) { + if (initAccum && length) { accumulator = array[++index]; } while (++index < length) { @@ -189,7 +189,7 @@ var reIsNative = RegExp('^' + ); /** Built-in value references. */ -var _Symbol = global.Symbol, +var Symbol = global.Symbol, Uint8Array = global.Uint8Array, getOwnPropertySymbols = Object.getOwnPropertySymbols; @@ -202,8 +202,8 @@ var mapCtorString = Map ? funcToString.call(Map) : '', setCtorString = Set ? funcToString.call(Set) : ''; /** Used to convert symbols to primitives and strings. */ -var symbolProto = _Symbol ? _Symbol.prototype : undefined, - symbolValueOf = _Symbol ? symbolProto.valueOf : undefined; +var symbolProto = Symbol ? Symbol.prototype : undefined, + symbolValueOf = Symbol ? symbolProto.valueOf : undefined; /** * Assigns `value` to `key` of `object` if the existing value is not equivalent @@ -395,7 +395,7 @@ function cloneSet(set) { * @returns {Object} Returns the cloned symbol object. */ function cloneSymbol(symbol) { - return _Symbol ? Object(symbolValueOf.call(symbol)) : {}; + return Symbol ? Object(symbolValueOf.call(symbol)) : {}; } /** @@ -617,7 +617,7 @@ function initCloneByTag(object, tag, isDeep) { * This method is like `_.clone` except that it accepts `customizer` which * is invoked to produce the cloned value. If `customizer` returns `undefined` * cloning is handled by the method instead. The `customizer` is invoked with - * up to five arguments; (value [, index|key, object, stack]). + * up to four arguments; (value [, index|key, object, stack]). * * @static * @memberOf _ @@ -633,7 +633,7 @@ function initCloneByTag(object, tag, isDeep) { * } * } * - * var el = _.clone(document.body, customizer); + * var el = _.cloneWith(document.body, customizer); * * console.log(el === document.body); * // => false diff --git a/lodash.clonewith/package.json b/lodash.clonewith/package.json index 8ee9cab75..d76e0d31f 100644 --- a/lodash.clonewith/package.json +++ b/lodash.clonewith/package.json @@ -1,6 +1,6 @@ { "name": "lodash.clonewith", - "version": "4.0.1", + "version": "4.0.2", "description": "The lodash method `_.cloneWith` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", diff --git a/lodash.cond/README.md b/lodash.cond/README.md index 5e4801c11..7aad064ea 100644 --- a/lodash.cond/README.md +++ b/lodash.cond/README.md @@ -1,4 +1,4 @@ -# lodash.cond v4.0.1 +# lodash.cond v4.0.2 The [lodash](https://lodash.com/) method `_.cond` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var cond = require('lodash.cond'); ``` -See the [documentation](https://lodash.com/docs#cond) or [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash.cond) for more details. +See the [documentation](https://lodash.com/docs#cond) or [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash.cond) for more details. diff --git a/lodash.cond/index.js b/lodash.cond/index.js index 4588c3e23..e1c001960 100644 --- a/lodash.cond/index.js +++ b/lodash.cond/index.js @@ -1,5 +1,5 @@ /** - * lodash 4.0.1 (Custom Build) + * lodash 4.0.2 (Custom Build) * Build: `lodash modularize exports="npm" -o ./` * Copyright 2012-2016 The Dojo Foundation * Based on Underscore.js 1.8.3 @@ -35,6 +35,38 @@ var reIsDeepProp = /\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/, /** Used to match backslashes in property paths. */ var reEscapeChar = /\\(\\)?/g; +/** Used to determine if values are of the language type `Object`. */ +var objectTypes = { + 'function': true, + 'object': true +}; + +/** Detect free variable `exports`. */ +var freeExports = (objectTypes[typeof exports] && exports && !exports.nodeType) ? exports : null; + +/** Detect free variable `module`. */ +var freeModule = (objectTypes[typeof module] && module && !module.nodeType) ? module : null; + +/** Detect free variable `global` from Node.js. */ +var freeGlobal = checkGlobal(freeExports && freeModule && typeof global == 'object' && global); + +/** Detect free variable `self`. */ +var freeSelf = checkGlobal(objectTypes[typeof self] && self); + +/** Detect free variable `window`. */ +var freeWindow = checkGlobal(objectTypes[typeof window] && window); + +/** Detect `this` as the global object. */ +var thisGlobal = checkGlobal(objectTypes[typeof this] && this); + +/** + * Used as a reference to the global object. + * + * The `this` value is used if it's the global object to avoid Greasemonkey's + * restricted `window` object, otherwise the `window` object is used. + */ +var root = freeGlobal || ((freeWindow !== (thisGlobal && thisGlobal.window)) && freeWindow) || freeSelf || thisGlobal || Function('return this')(); + /** * A faster alternative to `Function#apply`, this function invokes `func` * with the `this` binding of `thisArg` and the arguments of `args`. @@ -42,11 +74,11 @@ var reEscapeChar = /\\(\\)?/g; * @private * @param {Function} func The function to invoke. * @param {*} thisArg The `this` binding of `func`. - * @param {...*} [args] The arguments to invoke `func` with. + * @param {...*} args The arguments to invoke `func` with. * @returns {*} Returns the result of `func`. */ function apply(func, thisArg, args) { - var length = args ? args.length : 0; + var length = args.length; switch (length) { case 0: return func.call(thisArg); case 1: return func.call(thisArg, args[0]); @@ -56,8 +88,19 @@ function apply(func, thisArg, args) { return func.apply(thisArg, args); } +/** + * Checks if `value` is a global object. + * + * @private + * @param {*} value The value to check. + * @returns {null|Object} Returns `value` if it's a global object, else `null`. + */ +function checkGlobal(value) { + return (value && value.Object === Object) ? value : null; +} + /** Used for built-in method references. */ -var objectProto = global.Object.prototype; +var objectProto = Object.prototype; /** * Used to resolve the [`toStringTag`](http://ecma-international.org/ecma-262/6.0/#sec-object.prototype.tostring) @@ -66,7 +109,7 @@ var objectProto = global.Object.prototype; var objectToString = objectProto.toString; /** Built-in value references. */ -var Symbol = global.Symbol; +var Symbol = root.Symbol; /** Used to convert symbols to primitives and strings. */ var symbolProto = Symbol ? Symbol.prototype : undefined, diff --git a/lodash.cond/package.json b/lodash.cond/package.json index 88fe85bed..2dee91560 100644 --- a/lodash.cond/package.json +++ b/lodash.cond/package.json @@ -1,11 +1,11 @@ { "name": "lodash.cond", - "version": "4.0.1", + "version": "4.0.2", "description": "The lodash method `_.cond` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", "license": "MIT", - "keywords": "lodash, lodash-modularized, stdlib, util, cond", + "keywords": "lodash-modularized, cond", "author": "John-David Dalton (http://allyoucanleet.com/)", "contributors": [ "John-David Dalton (http://allyoucanleet.com/)", diff --git a/lodash.conforms/README.md b/lodash.conforms/README.md index e1ebe2803..128b46198 100644 --- a/lodash.conforms/README.md +++ b/lodash.conforms/README.md @@ -1,4 +1,4 @@ -# lodash.conforms v4.0.1 +# lodash.conforms v4.0.2 The [lodash](https://lodash.com/) method `_.conforms` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var conforms = require('lodash.conforms'); ``` -See the [documentation](https://lodash.com/docs#conforms) or [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash.conforms) for more details. +See the [documentation](https://lodash.com/docs#conforms) or [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash.conforms) for more details. diff --git a/lodash.conforms/index.js b/lodash.conforms/index.js index 5d5deca8f..efffd5e3d 100644 --- a/lodash.conforms/index.js +++ b/lodash.conforms/index.js @@ -1,5 +1,5 @@ /** - * lodash 4.0.0 (Custom Build) + * lodash 4.0.2 (Custom Build) * Build: `lodash modularize exports="npm" -o ./` * Copyright 2012-2016 The Dojo Foundation * Based on Underscore.js 1.8.3 @@ -98,14 +98,14 @@ function addSetEntry(set, value) { * @param {Array} array The array to iterate over. * @param {Function} iteratee The function invoked per iteration. * @param {*} [accumulator] The initial value. - * @param {boolean} [initFromArray] Specify using the first element of `array` as the initial value. + * @param {boolean} [initAccum] Specify using the first element of `array` as the initial value. * @returns {*} Returns the accumulated value. */ -function arrayReduce(array, iteratee, accumulator, initFromArray) { +function arrayReduce(array, iteratee, accumulator, initAccum) { var index = -1, length = array.length; - if (initFromArray && length) { + if (initAccum && length) { accumulator = array[++index]; } while (++index < length) { @@ -189,7 +189,7 @@ var reIsNative = RegExp('^' + ); /** Built-in value references. */ -var _Symbol = global.Symbol, +var Symbol = global.Symbol, Uint8Array = global.Uint8Array, getOwnPropertySymbols = Object.getOwnPropertySymbols; @@ -202,8 +202,8 @@ var mapCtorString = Map ? funcToString.call(Map) : '', setCtorString = Set ? funcToString.call(Set) : ''; /** Used to convert symbols to primitives and strings. */ -var symbolProto = _Symbol ? _Symbol.prototype : undefined, - symbolValueOf = _Symbol ? symbolProto.valueOf : undefined; +var symbolProto = Symbol ? Symbol.prototype : undefined, + symbolValueOf = Symbol ? symbolProto.valueOf : undefined; /** * Assigns `value` to `key` of `object` if the existing value is not equivalent @@ -424,7 +424,7 @@ function cloneSet(set) { * @returns {Object} Returns the cloned symbol object. */ function cloneSymbol(symbol) { - return _Symbol ? Object(symbolValueOf.call(symbol)) : {}; + return Symbol ? Object(symbolValueOf.call(symbol)) : {}; } /** diff --git a/lodash.conforms/package.json b/lodash.conforms/package.json index a91963898..865e74028 100644 --- a/lodash.conforms/package.json +++ b/lodash.conforms/package.json @@ -1,6 +1,6 @@ { "name": "lodash.conforms", - "version": "4.0.1", + "version": "4.0.2", "description": "The lodash method `_.conforms` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", diff --git a/lodash.countby/README.md b/lodash.countby/README.md index b4a03f453..ad27b0fbe 100644 --- a/lodash.countby/README.md +++ b/lodash.countby/README.md @@ -1,4 +1,4 @@ -# lodash.countby v4.0.1 +# lodash.countby v4.0.2 The [lodash](https://lodash.com/) method `_.countBy` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var countBy = require('lodash.countby'); ``` -See the [documentation](https://lodash.com/docs#countBy) or [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash.countby) for more details. +See the [documentation](https://lodash.com/docs#countBy) or [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash.countby) for more details. diff --git a/lodash.countby/index.js b/lodash.countby/index.js index 29c34c2fd..471aeb466 100644 --- a/lodash.countby/index.js +++ b/lodash.countby/index.js @@ -1,5 +1,5 @@ /** - * lodash 4.0.1 (Custom Build) + * lodash 4.0.2 (Custom Build) * Build: `lodash modularize exports="npm" -o ./` * Copyright 2012-2016 The Dojo Foundation * Based on Underscore.js 1.8.3 @@ -31,6 +31,27 @@ var reIsDeepProp = /\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/, /** Used to match backslashes in property paths. */ var reEscapeChar = /\\(\\)?/g; +/** + * A specialized version of `baseAggregator` for arrays. + * + * @private + * @param {Array} array The array to iterate over. + * @param {Function} setter The function to set `accumulator` values. + * @param {Function} iteratee The iteratee to transform keys. + * @param {Object} accumulator The initial aggregated object. + * @returns {Function} Returns `accumulator`. + */ +function arrayAggregator(array, setter, iteratee, accumulator) { + var index = -1, + length = array.length; + + while (++index < length) { + var value = array[index]; + setter(accumulator, value, iteratee(value), array); + } + return accumulator; +} + /** Used for built-in method references. */ var objectProto = global.Object.prototype; @@ -50,6 +71,24 @@ var Symbol = global.Symbol; var symbolProto = Symbol ? Symbol.prototype : undefined, symbolToString = Symbol ? symbolProto.toString : undefined; +/** + * Aggregates elements of `collection` on `accumulator` with keys transformed + * by `iteratee` and values set by `setter`. + * + * @private + * @param {Array|Object} collection The collection to iterate over. + * @param {Function} setter The function to set `accumulator` values. + * @param {Function} iteratee The iteratee to transform keys. + * @param {Object} accumulator The initial aggregated object. + * @returns {Function} Returns `accumulator`. + */ +function baseAggregator(collection, setter, iteratee, accumulator) { + baseEach(collection, function(value, key, collection) { + setter(accumulator, value, iteratee(value), collection); + }); + return accumulator; +} + /** * The base implementation of `_.get` without support for default values. * @@ -178,29 +217,16 @@ function baseToPath(value) { * Creates a function like `_.groupBy`. * * @private - * @param {Function} setter The function to set keys and values of the accumulator object. - * @param {Function} [initializer] The function to initialize the accumulator object. + * @param {Function} setter The function to set accumulator values. + * @param {Function} [initializer] The accumulator object initializer. * @returns {Function} Returns the new aggregator function. */ function createAggregator(setter, initializer) { return function(collection, iteratee) { - var result = initializer ? initializer() : {}; - iteratee = baseIteratee(iteratee); + var func = isArray(collection) ? arrayAggregator : baseAggregator, + accumulator = initializer ? initializer() : {}; - if (isArray(collection)) { - var index = -1, - length = collection.length; - - while (++index < length) { - var value = collection[index]; - setter(result, value, iteratee(value), collection); - } - } else { - baseEach(collection, function(value, key, collection) { - setter(result, value, iteratee(value), collection); - }); - } - return result; + return func(collection, setter, baseIteratee(iteratee), accumulator); }; } @@ -338,8 +364,6 @@ var isArray = Array.isArray; * // => false */ function isObject(value) { - // Avoid a V8 JIT bug in Chrome 19-20. - // See https://code.google.com/p/v8/issues/detail?id=2291 for more details. var type = typeof value; return !!value && (type == 'object' || type == 'function'); } diff --git a/lodash.countby/package.json b/lodash.countby/package.json index 64cce5515..5d422c98a 100644 --- a/lodash.countby/package.json +++ b/lodash.countby/package.json @@ -1,11 +1,11 @@ { "name": "lodash.countby", - "version": "4.0.1", + "version": "4.0.2", "description": "The lodash method `_.countBy` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", "license": "MIT", - "keywords": "lodash, lodash-modularized, stdlib, util, countby", + "keywords": "lodash-modularized, countby", "author": "John-David Dalton (http://allyoucanleet.com/)", "contributors": [ "John-David Dalton (http://allyoucanleet.com/)", diff --git a/lodash.create/LICENSE b/lodash.create/LICENSE index b054ca5a3..bcbe13d67 100644 --- a/lodash.create/LICENSE +++ b/lodash.create/LICENSE @@ -1,22 +1,23 @@ +The MIT License (MIT) + Copyright 2012-2016 The Dojo Foundation Based on Underscore.js, copyright 2009-2016 Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors -Permission is hereby granted, free of charge, to any person obtaining -a copy of this software and associated documentation files (the -"Software"), to deal in the Software without restriction, including -without limitation the rights to use, copy, modify, merge, publish, -distribute, sublicense, and/or sell copies of the Software, and to -permit persons to whom the Software is furnished to do so, subject to -the following conditions: +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: -The above copyright notice and this permission notice shall be -included in all copies or substantial portions of the Software. +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, -EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND -NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE -LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION -OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION -WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. diff --git a/lodash.create/README.md b/lodash.create/README.md index 734c4276d..7c7f372fd 100644 --- a/lodash.create/README.md +++ b/lodash.create/README.md @@ -1,4 +1,4 @@ -# lodash.create v4.0.1 +# lodash.create v4.0.2 The [lodash](https://lodash.com/) method `_.create` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var create = require('lodash.create'); ``` -See the [documentation](https://lodash.com/docs#create) or [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash.create) for more details. +See the [documentation](https://lodash.com/docs#create) or [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash.create) for more details. diff --git a/lodash.create/index.js b/lodash.create/index.js index ccfa71715..17513125a 100644 --- a/lodash.create/index.js +++ b/lodash.create/index.js @@ -1,5 +1,5 @@ /** - * lodash 4.0.1 (Custom Build) + * lodash 4.0.2 (Custom Build) * Build: `lodash modularize exports="npm" -o ./` * Copyright 2012-2016 The Dojo Foundation * Based on Underscore.js 1.8.3 @@ -14,6 +14,9 @@ var objectProto = Object.prototype; /** Used to check objects for own properties. */ var hasOwnProperty = objectProto.hasOwnProperty; +/** Built-in value references. */ +var objectCreate = Object.create; + /** * Assigns `value` to `key` of `object` if the existing value is not equivalent * using [`SameValueZero`](http://ecma-international.org/ecma-262/6.0/#sec-samevaluezero) @@ -54,17 +57,9 @@ function baseAssign(object, source) { * @param {Object} prototype The object to inherit from. * @returns {Object} Returns the new object. */ -var baseCreate = (function() { - function object() {} - return function(prototype) { - if (isObject(prototype)) { - object.prototype = prototype; - var result = new object; - object.prototype = undefined; - } - return result || {}; - }; -}()); +function baseCreate(proto) { + return isObject(proto) ? objectCreate(proto) : {}; +} /** * Copies properties of `source` to `object`. @@ -97,8 +92,11 @@ function copyObjectWith(source, props, object, customizer) { length = props.length; while (++index < length) { - var key = props[index], - newValue = customizer ? customizer(object[key], source[key], key, object, source) : source[key]; + var key = props[index]; + + var newValue = customizer + ? customizer(object[key], source[key], key, object, source) + : source[key]; assignValue(object, key, newValue); } diff --git a/lodash.create/package.json b/lodash.create/package.json index 2434f405b..5ff406fe1 100644 --- a/lodash.create/package.json +++ b/lodash.create/package.json @@ -1,6 +1,6 @@ { "name": "lodash.create", - "version": "4.0.1", + "version": "4.0.2", "description": "The lodash method `_.create` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", diff --git a/lodash.debounce/LICENSE b/lodash.debounce/LICENSE index b054ca5a3..bcbe13d67 100644 --- a/lodash.debounce/LICENSE +++ b/lodash.debounce/LICENSE @@ -1,22 +1,23 @@ +The MIT License (MIT) + Copyright 2012-2016 The Dojo Foundation Based on Underscore.js, copyright 2009-2016 Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors -Permission is hereby granted, free of charge, to any person obtaining -a copy of this software and associated documentation files (the -"Software"), to deal in the Software without restriction, including -without limitation the rights to use, copy, modify, merge, publish, -distribute, sublicense, and/or sell copies of the Software, and to -permit persons to whom the Software is furnished to do so, subject to -the following conditions: +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: -The above copyright notice and this permission notice shall be -included in all copies or substantial portions of the Software. +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, -EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND -NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE -LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION -OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION -WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. diff --git a/lodash.debounce/README.md b/lodash.debounce/README.md index a807d0624..8871340b4 100644 --- a/lodash.debounce/README.md +++ b/lodash.debounce/README.md @@ -1,4 +1,4 @@ -# lodash.debounce v4.0.1 +# lodash.debounce v4.0.2 The [lodash](https://lodash.com/) method `_.debounce` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var debounce = require('lodash.debounce'); ``` -See the [documentation](https://lodash.com/docs#debounce) or [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash.debounce) for more details. +See the [documentation](https://lodash.com/docs#debounce) or [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash.debounce) for more details. diff --git a/lodash.debounce/index.js b/lodash.debounce/index.js index 141e24904..dac419f4b 100644 --- a/lodash.debounce/index.js +++ b/lodash.debounce/index.js @@ -1,5 +1,5 @@ /** - * lodash 4.0.1 (Custom Build) + * lodash 4.0.2 (Custom Build) * Build: `lodash modularize exports="npm" -o ./` * Copyright 2012-2016 The Dojo Foundation * Based on Underscore.js 1.8.3 @@ -189,7 +189,7 @@ function debounce(func, wait, options) { if (maxWait === false) { var leadingCall = leading && !timeoutId; } else { - if (!maxTimeoutId && !leading) { + if (!lastCalled && !maxTimeoutId && !leading) { lastCalled = stamp; } var remaining = maxWait - (stamp - lastCalled), diff --git a/lodash.debounce/package.json b/lodash.debounce/package.json index 97046653e..dbb8d375e 100644 --- a/lodash.debounce/package.json +++ b/lodash.debounce/package.json @@ -1,6 +1,6 @@ { "name": "lodash.debounce", - "version": "4.0.1", + "version": "4.0.2", "description": "The lodash method `_.debounce` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", diff --git a/lodash.defaultsdeep/README.md b/lodash.defaultsdeep/README.md index 9b6533078..b3972ba0f 100644 --- a/lodash.defaultsdeep/README.md +++ b/lodash.defaultsdeep/README.md @@ -1,4 +1,4 @@ -# lodash.defaultsdeep v4.0.1 +# lodash.defaultsdeep v4.0.2 The [lodash](https://lodash.com/) method `_.defaultsDeep` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var defaultsDeep = require('lodash.defaultsdeep'); ``` -See the [documentation](https://lodash.com/docs#defaultsDeep) or [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash.defaultsdeep) for more details. +See the [documentation](https://lodash.com/docs#defaultsDeep) or [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash.defaultsdeep) for more details. diff --git a/lodash.defaultsdeep/index.js b/lodash.defaultsdeep/index.js index 4a410518c..2721dd130 100644 --- a/lodash.defaultsdeep/index.js +++ b/lodash.defaultsdeep/index.js @@ -1,5 +1,5 @@ /** - * lodash 4.0.0 (Custom Build) + * lodash 4.0.2 (Custom Build) * Build: `lodash modularize exports="npm" -o ./` * Copyright 2012-2016 The Dojo Foundation * Based on Underscore.js 1.8.3 @@ -141,14 +141,14 @@ function apply(func, thisArg, args) { * @param {Array} array The array to iterate over. * @param {Function} iteratee The function invoked per iteration. * @param {*} [accumulator] The initial value. - * @param {boolean} [initFromArray] Specify using the first element of `array` as the initial value. + * @param {boolean} [initAccum] Specify using the first element of `array` as the initial value. * @returns {*} Returns the accumulated value. */ -function arrayReduce(array, iteratee, accumulator, initFromArray) { +function arrayReduce(array, iteratee, accumulator, initAccum) { var index = -1, length = array.length; - if (initFromArray && length) { + if (initAccum && length) { accumulator = array[++index]; } while (++index < length) { @@ -232,7 +232,7 @@ var reIsNative = RegExp('^' + ); /** Built-in value references. */ -var _Symbol = global.Symbol, +var Symbol = global.Symbol, Uint8Array = global.Uint8Array, getOwnPropertySymbols = Object.getOwnPropertySymbols, propertyIsEnumerable = objectProto.propertyIsEnumerable; @@ -246,8 +246,8 @@ var mapCtorString = Map ? funcToString.call(Map) : '', setCtorString = Set ? funcToString.call(Set) : ''; /** Used to convert symbols to primitives and strings. */ -var symbolProto = _Symbol ? _Symbol.prototype : undefined, - symbolValueOf = _Symbol ? symbolProto.valueOf : undefined; +var symbolProto = Symbol ? Symbol.prototype : undefined, + symbolValueOf = Symbol ? symbolProto.valueOf : undefined; /** * This function is like `assignValue` except that it doesn't assign `undefined` values. @@ -397,10 +397,11 @@ function baseForOwn(object, iteratee) { * @private * @param {Object} object The destination object. * @param {Object} source The source object. + * @param {number} srcIndex The index of `source`. * @param {Function} [customizer] The function to customize merged values. * @param {Object} [stack] Tracks traversed source values and their merged counterparts. */ -function baseMerge(object, source, customizer, stack) { +function baseMerge(object, source, srcIndex, customizer, stack) { if (object === source) { return; } @@ -412,7 +413,7 @@ function baseMerge(object, source, customizer, stack) { } if (isObject(srcValue)) { stack || (stack = new Stack); - baseMergeDeep(object, source, key, baseMerge, customizer, stack); + baseMergeDeep(object, source, key, srcIndex, baseMerge, customizer, stack); } else { var newValue = customizer ? customizer(object[key], srcValue, (key + ''), object, source, stack) : undefined; @@ -433,11 +434,12 @@ function baseMerge(object, source, customizer, stack) { * @param {Object} object The destination object. * @param {Object} source The source object. * @param {string} key The key of the value to merge. + * @param {number} srcIndex The index of `source`. * @param {Function} mergeFunc The function to merge values. * @param {Function} [customizer] The function to customize assigned values. * @param {Object} [stack] Tracks traversed source values and their merged counterparts. */ -function baseMergeDeep(object, source, key, mergeFunc, customizer, stack) { +function baseMergeDeep(object, source, key, srcIndex, mergeFunc, customizer, stack) { var objValue = object[key], srcValue = source[key], stacked = stack.get(srcValue) || stack.get(objValue); @@ -452,24 +454,36 @@ function baseMergeDeep(object, source, key, mergeFunc, customizer, stack) { if (isCommon) { newValue = srcValue; if (isArray(srcValue) || isTypedArray(srcValue)) { - newValue = isArray(objValue) - ? objValue - : ((isArrayLikeObject(objValue)) ? copyArray(objValue) : baseClone(srcValue)); + if (isArray(objValue)) { + newValue = srcIndex ? copyArray(objValue) : objValue; + } + else if (isArrayLikeObject(objValue)) { + newValue = copyArray(objValue); + } + else { + newValue = baseClone(srcValue); + } } else if (isPlainObject(srcValue) || isArguments(srcValue)) { - newValue = isArguments(objValue) - ? toPlainObject(objValue) - : (isObject(objValue) ? objValue : baseClone(srcValue)); + if (isArguments(objValue)) { + newValue = toPlainObject(objValue); + } + else if (!isObject(objValue) || (srcIndex && isFunction(objValue))) { + newValue = baseClone(srcValue); + } + else { + newValue = srcIndex ? baseClone(objValue) : objValue; + } } else { - isCommon = isFunction(srcValue); + isCommon = false; } } stack.set(srcValue, newValue); if (isCommon) { // Recursively merge objects and arrays (susceptible to call stack limits). - mergeFunc(newValue, srcValue, customizer, stack); + mergeFunc(newValue, srcValue, srcIndex, customizer, stack); } assignMergeValue(object, key, newValue); } @@ -550,7 +564,7 @@ function cloneSet(set) { * @returns {Object} Returns the cloned symbol object. */ function cloneSymbol(symbol) { - return _Symbol ? Object(symbolValueOf.call(symbol)) : {}; + return Symbol ? Object(symbolValueOf.call(symbol)) : {}; } /** @@ -795,9 +809,9 @@ function initCloneByTag(object, tag, isDeep) { function mergeDefaults(objValue, srcValue, key, object, source, stack) { if (isObject(objValue) && isObject(srcValue)) { stack.set(srcValue, objValue); - baseMerge(objValue, srcValue, mergeDefaults, stack); + baseMerge(objValue, srcValue, undefined, mergeDefaults, stack); } - return objValue === undefined ? baseClone(srcValue) : objValue; + return objValue; } /** diff --git a/lodash.defaultsdeep/package.json b/lodash.defaultsdeep/package.json index 53fb8b653..66c4e4a9a 100644 --- a/lodash.defaultsdeep/package.json +++ b/lodash.defaultsdeep/package.json @@ -1,6 +1,6 @@ { "name": "lodash.defaultsdeep", - "version": "4.0.1", + "version": "4.0.2", "description": "The lodash method `_.defaultsDeep` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", diff --git a/lodash.delay/LICENSE b/lodash.delay/LICENSE index b054ca5a3..e0c69d560 100644 --- a/lodash.delay/LICENSE +++ b/lodash.delay/LICENSE @@ -1,7 +1,17 @@ -Copyright 2012-2016 The Dojo Foundation -Based on Underscore.js, copyright 2009-2016 Jeremy Ashkenas, +Copyright jQuery Foundation and other contributors + +Based on Underscore.js, copyright Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors +This software consists of voluntary contributions made by many +individuals. For exact contribution history, see the revision history +available at https://github.com/lodash/lodash + +The following license applies to all parts of this software except as +documented below: + +==== + Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including @@ -20,3 +30,18 @@ NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + +==== + +Copyright and related rights for sample code are waived via CC0. Sample +code is defined as all source code displayed within the prose of the +documentation. + +CC0: http://creativecommons.org/publicdomain/zero/1.0/ + +==== + +Files located in the node_modules and vendor directories are externally +maintained libraries used by this software which have their own +licenses; we recommend you read them, as their terms may differ from the +terms above. diff --git a/lodash.delay/README.md b/lodash.delay/README.md index 3b690dc93..c40c2420e 100644 --- a/lodash.delay/README.md +++ b/lodash.delay/README.md @@ -1,4 +1,4 @@ -# lodash.delay v4.0.1 +# lodash.delay v4.0.2 The [lodash](https://lodash.com/) method `_.delay` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var delay = require('lodash.delay'); ``` -See the [documentation](https://lodash.com/docs#delay) or [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash.delay) for more details. +See the [documentation](https://lodash.com/docs#delay) or [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash.delay) for more details. diff --git a/lodash.delay/index.js b/lodash.delay/index.js index b79fef574..c5ee0c7c0 100644 --- a/lodash.delay/index.js +++ b/lodash.delay/index.js @@ -1,10 +1,10 @@ /** - * lodash 4.0.1 (Custom Build) + * lodash (Custom Build) * Build: `lodash modularize exports="npm" -o ./` - * Copyright 2012-2016 The Dojo Foundation + * Copyright jQuery Foundation and other contributors + * Released under MIT license * Based on Underscore.js 1.8.3 - * Copyright 2009-2016 Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors - * Available under MIT license + * Copyright Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors */ var rest = require('lodash.rest'); @@ -16,7 +16,8 @@ var NAN = 0 / 0; /** `Object#toString` result references. */ var funcTag = '[object Function]', - genTag = '[object GeneratorFunction]'; + genTag = '[object GeneratorFunction]', + symbolTag = '[object Symbol]'; /** Used to match leading and trailing whitespace. */ var reTrim = /^\s+|\s+$/g; @@ -37,7 +38,8 @@ var freeParseInt = parseInt; var objectProto = Object.prototype; /** - * Used to resolve the [`toStringTag`](http://ecma-international.org/ecma-262/6.0/#sec-object.prototype.tostring) + * Used to resolve the + * [`toStringTag`](http://ecma-international.org/ecma-262/6.0/#sec-object.prototype.tostring) * of values. */ var objectToString = objectProto.toString; @@ -65,6 +67,7 @@ function baseDelay(func, wait, args) { * * @static * @memberOf _ + * @since 0.1.0 * @category Function * @param {Function} func The function to delay. * @param {number} wait The number of milliseconds to delay invocation. @@ -75,7 +78,7 @@ function baseDelay(func, wait, args) { * _.delay(function(text) { * console.log(text); * }, 1000, 'later'); - * // => logs 'later' after one second + * // => Logs 'later' after one second. */ var delay = rest(function(func, wait, args) { return baseDelay(func, toNumber(wait) || 0, args); @@ -86,9 +89,11 @@ var delay = rest(function(func, wait, args) { * * @static * @memberOf _ + * @since 0.1.0 * @category Lang * @param {*} value The value to check. - * @returns {boolean} Returns `true` if `value` is correctly classified, else `false`. + * @returns {boolean} Returns `true` if `value` is correctly classified, + * else `false`. * @example * * _.isFunction(_); @@ -106,11 +111,13 @@ function isFunction(value) { } /** - * Checks if `value` is the [language type](https://es5.github.io/#x8) of `Object`. - * (e.g. arrays, functions, objects, regexes, `new Number(0)`, and `new String('')`) + * Checks if `value` is the + * [language type](http://www.ecma-international.org/ecma-262/6.0/#sec-ecmascript-language-types) + * of `Object`. (e.g. arrays, functions, objects, regexes, `new Number(0)`, and `new String('')`) * * @static * @memberOf _ + * @since 0.1.0 * @category Lang * @param {*} value The value to check. * @returns {boolean} Returns `true` if `value` is an object, else `false`. @@ -133,18 +140,70 @@ function isObject(value) { return !!value && (type == 'object' || type == 'function'); } +/** + * Checks if `value` is object-like. A value is object-like if it's not `null` + * and has a `typeof` result of "object". + * + * @static + * @memberOf _ + * @since 4.0.0 + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is object-like, else `false`. + * @example + * + * _.isObjectLike({}); + * // => true + * + * _.isObjectLike([1, 2, 3]); + * // => true + * + * _.isObjectLike(_.noop); + * // => false + * + * _.isObjectLike(null); + * // => false + */ +function isObjectLike(value) { + return !!value && typeof value == 'object'; +} + +/** + * Checks if `value` is classified as a `Symbol` primitive or object. + * + * @static + * @memberOf _ + * @since 4.0.0 + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is correctly classified, + * else `false`. + * @example + * + * _.isSymbol(Symbol.iterator); + * // => true + * + * _.isSymbol('abc'); + * // => false + */ +function isSymbol(value) { + return typeof value == 'symbol' || + (isObjectLike(value) && objectToString.call(value) == symbolTag); +} + /** * Converts `value` to a number. * * @static * @memberOf _ + * @since 4.0.0 * @category Lang * @param {*} value The value to process. * @returns {number} Returns the number. * @example * - * _.toNumber(3); - * // => 3 + * _.toNumber(3.2); + * // => 3.2 * * _.toNumber(Number.MIN_VALUE); * // => 5e-324 @@ -152,10 +211,16 @@ function isObject(value) { * _.toNumber(Infinity); * // => Infinity * - * _.toNumber('3'); - * // => 3 + * _.toNumber('3.2'); + * // => 3.2 */ function toNumber(value) { + if (typeof value == 'number') { + return value; + } + if (isSymbol(value)) { + return NAN; + } if (isObject(value)) { var other = isFunction(value.valueOf) ? value.valueOf() : value; value = isObject(other) ? (other + '') : other; diff --git a/lodash.delay/package.json b/lodash.delay/package.json index c0841a970..74434acff 100644 --- a/lodash.delay/package.json +++ b/lodash.delay/package.json @@ -1,6 +1,6 @@ { "name": "lodash.delay", - "version": "4.0.1", + "version": "4.0.2", "description": "The lodash method `_.delay` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", @@ -9,7 +9,7 @@ "author": "John-David Dalton (http://allyoucanleet.com/)", "contributors": [ "John-David Dalton (http://allyoucanleet.com/)", - "Blaine Bublitz (https://github.com/phated)", + "Blaine Bublitz (https://github.com/phated)", "Mathias Bynens (https://mathiasbynens.be/)" ], "repository": "lodash/lodash", diff --git a/lodash.difference/README.md b/lodash.difference/README.md index ed5980c99..b402864d8 100644 --- a/lodash.difference/README.md +++ b/lodash.difference/README.md @@ -1,4 +1,4 @@ -# lodash.difference v4.0.1 +# lodash.difference v4.0.2 The [lodash](https://lodash.com/) method `_.difference` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var difference = require('lodash.difference'); ``` -See the [documentation](https://lodash.com/docs#difference) or [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash.difference) for more details. +See the [documentation](https://lodash.com/docs#difference) or [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash.difference) for more details. diff --git a/lodash.difference/index.js b/lodash.difference/index.js index 676c8b466..2164cd150 100644 --- a/lodash.difference/index.js +++ b/lodash.difference/index.js @@ -1,5 +1,5 @@ /** - * lodash 4.0.1 (Custom Build) + * lodash 4.0.2 (Custom Build) * Build: `lodash modularize exports="npm" -o ./` * Copyright 2012-2016 The Dojo Foundation * Based on Underscore.js 1.8.3 @@ -38,7 +38,7 @@ function baseUnary(func) { } /** Used for built-in method references. */ -var objectProto = global.Object.prototype; +var objectProto = Object.prototype; /** * Used to resolve the [`toStringTag`](http://ecma-international.org/ecma-262/6.0/#sec-object.prototype.tostring) @@ -128,7 +128,7 @@ var getLength = baseProperty('length'); /** * Creates an array of unique `array` values not included in the other - * provided arrays using [`SameValueZero`](http://ecma-international.org/ecma-262/6.0/#sec-samevaluezero) + * given arrays using [`SameValueZero`](http://ecma-international.org/ecma-262/6.0/#sec-samevaluezero) * for equality comparisons. * * @static diff --git a/lodash.difference/package.json b/lodash.difference/package.json index 9c6071a9e..dc0b2f85c 100644 --- a/lodash.difference/package.json +++ b/lodash.difference/package.json @@ -1,11 +1,11 @@ { "name": "lodash.difference", - "version": "4.0.1", + "version": "4.0.2", "description": "The lodash method `_.difference` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", "license": "MIT", - "keywords": "lodash, lodash-modularized, stdlib, util, difference", + "keywords": "lodash-modularized, difference", "author": "John-David Dalton (http://allyoucanleet.com/)", "contributors": [ "John-David Dalton (http://allyoucanleet.com/)", diff --git a/lodash.differenceby/README.md b/lodash.differenceby/README.md index 74aa97ff9..2c4e58dcd 100644 --- a/lodash.differenceby/README.md +++ b/lodash.differenceby/README.md @@ -1,4 +1,4 @@ -# lodash.differenceby v4.0.1 +# lodash.differenceby v4.0.2 The [lodash](https://lodash.com/) method `_.differenceBy` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var differenceBy = require('lodash.differenceby'); ``` -See the [documentation](https://lodash.com/docs#differenceBy) or [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash.differenceby) for more details. +See the [documentation](https://lodash.com/docs#differenceBy) or [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash.differenceby) for more details. diff --git a/lodash.differenceby/index.js b/lodash.differenceby/index.js index efbce2084..6a25b7484 100644 --- a/lodash.differenceby/index.js +++ b/lodash.differenceby/index.js @@ -1,5 +1,5 @@ /** - * lodash 4.0.0 (Custom Build) + * lodash 4.0.2 (Custom Build) * Build: `lodash modularize exports="npm" -o ./` * Copyright 2012-2016 The Dojo Foundation * Based on Underscore.js 1.8.3 @@ -66,11 +66,11 @@ var objectProto = global.Object.prototype; var objectToString = objectProto.toString; /** Built-in value references. */ -var _Symbol = global.Symbol; +var Symbol = global.Symbol; /** Used to convert symbols to primitives and strings. */ -var symbolProto = _Symbol ? _Symbol.prototype : undefined, - symbolToString = _Symbol ? symbolProto.toString : undefined; +var symbolProto = Symbol ? Symbol.prototype : undefined, + symbolToString = Symbol ? symbolProto.toString : undefined; /** * The base implementation of methods like `_.difference` without support for @@ -532,8 +532,6 @@ function isLength(value) { * // => false */ function isObject(value) { - // Avoid a V8 JIT bug in Chrome 19-20. - // See https://code.google.com/p/v8/issues/detail?id=2291 for more details. var type = typeof value; return !!value && (type == 'object' || type == 'function'); } @@ -615,7 +613,7 @@ function toString(value) { return ''; } if (isSymbol(value)) { - return _Symbol ? symbolToString.call(value) : ''; + return Symbol ? symbolToString.call(value) : ''; } var result = (value + ''); return (result == '0' && (1 / value) == -INFINITY) ? '-0' : result; diff --git a/lodash.differenceby/package.json b/lodash.differenceby/package.json index 3186cfa64..6029d0e26 100644 --- a/lodash.differenceby/package.json +++ b/lodash.differenceby/package.json @@ -1,6 +1,6 @@ { "name": "lodash.differenceby", - "version": "4.0.1", + "version": "4.0.2", "description": "The lodash method `_.differenceBy` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", diff --git a/lodash.differencewith/README.md b/lodash.differencewith/README.md index ac25fb820..bcdf880a9 100644 --- a/lodash.differencewith/README.md +++ b/lodash.differencewith/README.md @@ -1,4 +1,4 @@ -# lodash.differencewith v4.0.1 +# lodash.differencewith v4.0.2 The [lodash](https://lodash.com/) method `_.differenceWith` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var differenceWith = require('lodash.differencewith'); ``` -See the [documentation](https://lodash.com/docs#differenceWith) or [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash.differencewith) for more details. +See the [documentation](https://lodash.com/docs#differenceWith) or [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash.differencewith) for more details. diff --git a/lodash.differencewith/index.js b/lodash.differencewith/index.js index 5fb27ab7a..70c34fb92 100644 --- a/lodash.differencewith/index.js +++ b/lodash.differencewith/index.js @@ -1,5 +1,5 @@ /** - * lodash 4.0.1 (Custom Build) + * lodash 4.0.2 (Custom Build) * Build: `lodash modularize exports="npm" -o ./` * Copyright 2012-2016 The Dojo Foundation * Based on Underscore.js 1.8.3 @@ -38,7 +38,7 @@ function baseUnary(func) { } /** Used for built-in method references. */ -var objectProto = global.Object.prototype; +var objectProto = Object.prototype; /** * Used to resolve the [`toStringTag`](http://ecma-international.org/ecma-262/6.0/#sec-object.prototype.tostring) diff --git a/lodash.differencewith/package.json b/lodash.differencewith/package.json index 85dbfdc8e..a79e81242 100644 --- a/lodash.differencewith/package.json +++ b/lodash.differencewith/package.json @@ -1,11 +1,11 @@ { "name": "lodash.differencewith", - "version": "4.0.1", + "version": "4.0.2", "description": "The lodash method `_.differenceWith` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", "license": "MIT", - "keywords": "lodash, lodash-modularized, stdlib, util, differencewith", + "keywords": "lodash-modularized, differencewith", "author": "John-David Dalton (http://allyoucanleet.com/)", "contributors": [ "John-David Dalton (http://allyoucanleet.com/)", diff --git a/lodash.drop/LICENSE b/lodash.drop/LICENSE index b054ca5a3..bcbe13d67 100644 --- a/lodash.drop/LICENSE +++ b/lodash.drop/LICENSE @@ -1,22 +1,23 @@ +The MIT License (MIT) + Copyright 2012-2016 The Dojo Foundation Based on Underscore.js, copyright 2009-2016 Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors -Permission is hereby granted, free of charge, to any person obtaining -a copy of this software and associated documentation files (the -"Software"), to deal in the Software without restriction, including -without limitation the rights to use, copy, modify, merge, publish, -distribute, sublicense, and/or sell copies of the Software, and to -permit persons to whom the Software is furnished to do so, subject to -the following conditions: +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: -The above copyright notice and this permission notice shall be -included in all copies or substantial portions of the Software. +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, -EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND -NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE -LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION -OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION -WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. diff --git a/lodash.drop/README.md b/lodash.drop/README.md index 19aaf0e40..48ffe0bbd 100644 --- a/lodash.drop/README.md +++ b/lodash.drop/README.md @@ -1,4 +1,4 @@ -# lodash.drop v4.0.1 +# lodash.drop v4.0.2 The [lodash](https://lodash.com/) method `_.drop` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var drop = require('lodash.drop'); ``` -See the [documentation](https://lodash.com/docs#drop) or [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash.drop) for more details. +See the [documentation](https://lodash.com/docs#drop) or [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash.drop) for more details. diff --git a/lodash.drop/index.js b/lodash.drop/index.js index e2d19d79d..3090346ce 100644 --- a/lodash.drop/index.js +++ b/lodash.drop/index.js @@ -1,5 +1,5 @@ /** - * lodash 4.0.1 (Custom Build) + * lodash 4.0.2 (Custom Build) * Build: `lodash modularize exports="npm" -o ./` * Copyright 2012-2016 The Dojo Foundation * Based on Underscore.js 1.8.3 diff --git a/lodash.drop/package.json b/lodash.drop/package.json index b65c45ec6..cda1a5b60 100644 --- a/lodash.drop/package.json +++ b/lodash.drop/package.json @@ -1,6 +1,6 @@ { "name": "lodash.drop", - "version": "4.0.1", + "version": "4.0.2", "description": "The lodash method `_.drop` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", @@ -9,12 +9,12 @@ "author": "John-David Dalton (http://allyoucanleet.com/)", "contributors": [ "John-David Dalton (http://allyoucanleet.com/)", - "Blaine Bublitz (https://github.com/phated)", + "Blaine Bublitz (https://github.com/phated)", "Mathias Bynens (https://mathiasbynens.be/)" ], "repository": "lodash/lodash", "scripts": { "test": "echo \"See https://travis-ci.org/lodash/lodash-cli for testing details.\"" }, "dependencies": { - "lodash._baseslice": "^4.0.0" + "lodash._baseslice": "~4.0.0" } } diff --git a/lodash.dropright/LICENSE b/lodash.dropright/LICENSE index b054ca5a3..bcbe13d67 100644 --- a/lodash.dropright/LICENSE +++ b/lodash.dropright/LICENSE @@ -1,22 +1,23 @@ +The MIT License (MIT) + Copyright 2012-2016 The Dojo Foundation Based on Underscore.js, copyright 2009-2016 Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors -Permission is hereby granted, free of charge, to any person obtaining -a copy of this software and associated documentation files (the -"Software"), to deal in the Software without restriction, including -without limitation the rights to use, copy, modify, merge, publish, -distribute, sublicense, and/or sell copies of the Software, and to -permit persons to whom the Software is furnished to do so, subject to -the following conditions: +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: -The above copyright notice and this permission notice shall be -included in all copies or substantial portions of the Software. +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, -EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND -NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE -LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION -OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION -WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. diff --git a/lodash.dropright/README.md b/lodash.dropright/README.md index 07def113a..de9433d39 100644 --- a/lodash.dropright/README.md +++ b/lodash.dropright/README.md @@ -1,4 +1,4 @@ -# lodash.dropright v4.0.1 +# lodash.dropright v4.0.2 The [lodash](https://lodash.com/) method `_.dropRight` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var dropRight = require('lodash.dropright'); ``` -See the [documentation](https://lodash.com/docs#dropRight) or [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash.dropright) for more details. +See the [documentation](https://lodash.com/docs#dropRight) or [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash.dropright) for more details. diff --git a/lodash.dropright/index.js b/lodash.dropright/index.js index 831cf1ff0..63da366ce 100644 --- a/lodash.dropright/index.js +++ b/lodash.dropright/index.js @@ -1,5 +1,5 @@ /** - * lodash 4.0.1 (Custom Build) + * lodash 4.0.2 (Custom Build) * Build: `lodash modularize exports="npm" -o ./` * Copyright 2012-2016 The Dojo Foundation * Based on Underscore.js 1.8.3 diff --git a/lodash.dropright/package.json b/lodash.dropright/package.json index eb84b7fb2..e7b5e967c 100644 --- a/lodash.dropright/package.json +++ b/lodash.dropright/package.json @@ -1,6 +1,6 @@ { "name": "lodash.dropright", - "version": "4.0.1", + "version": "4.0.2", "description": "The lodash method `_.dropRight` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", @@ -9,12 +9,12 @@ "author": "John-David Dalton (http://allyoucanleet.com/)", "contributors": [ "John-David Dalton (http://allyoucanleet.com/)", - "Blaine Bublitz (https://github.com/phated)", + "Blaine Bublitz (https://github.com/phated)", "Mathias Bynens (https://mathiasbynens.be/)" ], "repository": "lodash/lodash", "scripts": { "test": "echo \"See https://travis-ci.org/lodash/lodash-cli for testing details.\"" }, "dependencies": { - "lodash._baseslice": "^4.0.0" + "lodash._baseslice": "~4.0.0" } } diff --git a/lodash.droprightwhile/README.md b/lodash.droprightwhile/README.md index 32137ced8..b2b8d8395 100644 --- a/lodash.droprightwhile/README.md +++ b/lodash.droprightwhile/README.md @@ -1,4 +1,4 @@ -# lodash.droprightwhile v4.0.1 +# lodash.droprightwhile v4.0.2 The [lodash](https://lodash.com/) method `_.dropRightWhile` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var dropRightWhile = require('lodash.droprightwhile'); ``` -See the [documentation](https://lodash.com/docs#dropRightWhile) or [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash.droprightwhile) for more details. +See the [documentation](https://lodash.com/docs#dropRightWhile) or [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash.droprightwhile) for more details. diff --git a/lodash.droprightwhile/index.js b/lodash.droprightwhile/index.js index e19271402..4b8798a7e 100644 --- a/lodash.droprightwhile/index.js +++ b/lodash.droprightwhile/index.js @@ -1,5 +1,5 @@ /** - * lodash 4.0.1 (Custom Build) + * lodash 4.0.2 (Custom Build) * Build: `lodash modularize exports="npm" -o ./` * Copyright 2012-2016 The Dojo Foundation * Based on Underscore.js 1.8.3 @@ -31,8 +31,51 @@ var reIsDeepProp = /\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/, /** Used to match backslashes in property paths. */ var reEscapeChar = /\\(\\)?/g; +/** Used to determine if values are of the language type `Object`. */ +var objectTypes = { + 'function': true, + 'object': true +}; + +/** Detect free variable `exports`. */ +var freeExports = (objectTypes[typeof exports] && exports && !exports.nodeType) ? exports : null; + +/** Detect free variable `module`. */ +var freeModule = (objectTypes[typeof module] && module && !module.nodeType) ? module : null; + +/** Detect free variable `global` from Node.js. */ +var freeGlobal = checkGlobal(freeExports && freeModule && typeof global == 'object' && global); + +/** Detect free variable `self`. */ +var freeSelf = checkGlobal(objectTypes[typeof self] && self); + +/** Detect free variable `window`. */ +var freeWindow = checkGlobal(objectTypes[typeof window] && window); + +/** Detect `this` as the global object. */ +var thisGlobal = checkGlobal(objectTypes[typeof this] && this); + +/** + * Used as a reference to the global object. + * + * The `this` value is used if it's the global object to avoid Greasemonkey's + * restricted `window` object, otherwise the `window` object is used. + */ +var root = freeGlobal || ((freeWindow !== (thisGlobal && thisGlobal.window)) && freeWindow) || freeSelf || thisGlobal || Function('return this')(); + +/** + * Checks if `value` is a global object. + * + * @private + * @param {*} value The value to check. + * @returns {null|Object} Returns `value` if it's a global object, else `null`. + */ +function checkGlobal(value) { + return (value && value.Object === Object) ? value : null; +} + /** Used for built-in method references. */ -var objectProto = global.Object.prototype; +var objectProto = Object.prototype; /** * Used to resolve the [`toStringTag`](http://ecma-international.org/ecma-262/6.0/#sec-object.prototype.tostring) @@ -41,7 +84,7 @@ var objectProto = global.Object.prototype; var objectToString = objectProto.toString; /** Built-in value references. */ -var Symbol = global.Symbol; +var Symbol = root.Symbol; /** Used to convert symbols to primitives and strings. */ var symbolProto = Symbol ? Symbol.prototype : undefined, @@ -277,15 +320,15 @@ function stringToPath(string) { * _.dropRightWhile(users, function(o) { return !o.active; }); * // => objects for ['barney'] * - * // using the `_.matches` iteratee shorthand + * // The `_.matches` iteratee shorthand. * _.dropRightWhile(users, { 'user': 'pebbles', 'active': false }); * // => objects for ['barney', 'fred'] * - * // using the `_.matchesProperty` iteratee shorthand + * // The `_.matchesProperty` iteratee shorthand. * _.dropRightWhile(users, ['active', false]); * // => objects for ['barney'] * - * // using the `_.property` iteratee shorthand + * // The `_.property` iteratee shorthand. * _.dropRightWhile(users, 'active'); * // => objects for ['barney', 'fred', 'pebbles'] */ diff --git a/lodash.droprightwhile/package.json b/lodash.droprightwhile/package.json index a8b12aac5..0944331bf 100644 --- a/lodash.droprightwhile/package.json +++ b/lodash.droprightwhile/package.json @@ -1,11 +1,11 @@ { "name": "lodash.droprightwhile", - "version": "4.0.1", + "version": "4.0.2", "description": "The lodash method `_.dropRightWhile` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", "license": "MIT", - "keywords": "lodash, lodash-modularized, stdlib, util, droprightwhile", + "keywords": "lodash-modularized, droprightwhile", "author": "John-David Dalton (http://allyoucanleet.com/)", "contributors": [ "John-David Dalton (http://allyoucanleet.com/)", diff --git a/lodash.dropwhile/README.md b/lodash.dropwhile/README.md index de42d24bb..0c3b4edd4 100644 --- a/lodash.dropwhile/README.md +++ b/lodash.dropwhile/README.md @@ -1,4 +1,4 @@ -# lodash.dropwhile v4.0.1 +# lodash.dropwhile v4.0.2 The [lodash](https://lodash.com/) method `_.dropWhile` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var dropWhile = require('lodash.dropwhile'); ``` -See the [documentation](https://lodash.com/docs#dropWhile) or [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash.dropwhile) for more details. +See the [documentation](https://lodash.com/docs#dropWhile) or [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash.dropwhile) for more details. diff --git a/lodash.dropwhile/index.js b/lodash.dropwhile/index.js index 270e007a0..4e8aa6759 100644 --- a/lodash.dropwhile/index.js +++ b/lodash.dropwhile/index.js @@ -1,5 +1,5 @@ /** - * lodash 4.0.1 (Custom Build) + * lodash 4.0.2 (Custom Build) * Build: `lodash modularize exports="npm" -o ./` * Copyright 2012-2016 The Dojo Foundation * Based on Underscore.js 1.8.3 @@ -31,8 +31,51 @@ var reIsDeepProp = /\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/, /** Used to match backslashes in property paths. */ var reEscapeChar = /\\(\\)?/g; +/** Used to determine if values are of the language type `Object`. */ +var objectTypes = { + 'function': true, + 'object': true +}; + +/** Detect free variable `exports`. */ +var freeExports = (objectTypes[typeof exports] && exports && !exports.nodeType) ? exports : null; + +/** Detect free variable `module`. */ +var freeModule = (objectTypes[typeof module] && module && !module.nodeType) ? module : null; + +/** Detect free variable `global` from Node.js. */ +var freeGlobal = checkGlobal(freeExports && freeModule && typeof global == 'object' && global); + +/** Detect free variable `self`. */ +var freeSelf = checkGlobal(objectTypes[typeof self] && self); + +/** Detect free variable `window`. */ +var freeWindow = checkGlobal(objectTypes[typeof window] && window); + +/** Detect `this` as the global object. */ +var thisGlobal = checkGlobal(objectTypes[typeof this] && this); + +/** + * Used as a reference to the global object. + * + * The `this` value is used if it's the global object to avoid Greasemonkey's + * restricted `window` object, otherwise the `window` object is used. + */ +var root = freeGlobal || ((freeWindow !== (thisGlobal && thisGlobal.window)) && freeWindow) || freeSelf || thisGlobal || Function('return this')(); + +/** + * Checks if `value` is a global object. + * + * @private + * @param {*} value The value to check. + * @returns {null|Object} Returns `value` if it's a global object, else `null`. + */ +function checkGlobal(value) { + return (value && value.Object === Object) ? value : null; +} + /** Used for built-in method references. */ -var objectProto = global.Object.prototype; +var objectProto = Object.prototype; /** * Used to resolve the [`toStringTag`](http://ecma-international.org/ecma-262/6.0/#sec-object.prototype.tostring) @@ -41,7 +84,7 @@ var objectProto = global.Object.prototype; var objectToString = objectProto.toString; /** Built-in value references. */ -var Symbol = global.Symbol; +var Symbol = root.Symbol; /** Used to convert symbols to primitives and strings. */ var symbolProto = Symbol ? Symbol.prototype : undefined, @@ -277,15 +320,15 @@ function stringToPath(string) { * _.dropWhile(users, function(o) { return !o.active; }); * // => objects for ['pebbles'] * - * // using the `_.matches` iteratee shorthand + * // The `_.matches` iteratee shorthand. * _.dropWhile(users, { 'user': 'barney', 'active': false }); * // => objects for ['fred', 'pebbles'] * - * // using the `_.matchesProperty` iteratee shorthand + * // The `_.matchesProperty` iteratee shorthand. * _.dropWhile(users, ['active', false]); * // => objects for ['pebbles'] * - * // using the `_.property` iteratee shorthand + * // The `_.property` iteratee shorthand. * _.dropWhile(users, 'active'); * // => objects for ['barney', 'fred', 'pebbles'] */ diff --git a/lodash.dropwhile/package.json b/lodash.dropwhile/package.json index 3b2810136..b3c77b193 100644 --- a/lodash.dropwhile/package.json +++ b/lodash.dropwhile/package.json @@ -1,11 +1,11 @@ { "name": "lodash.dropwhile", - "version": "4.0.1", + "version": "4.0.2", "description": "The lodash method `_.dropWhile` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", "license": "MIT", - "keywords": "lodash, lodash-modularized, stdlib, util, dropwhile", + "keywords": "lodash-modularized, dropwhile", "author": "John-David Dalton (http://allyoucanleet.com/)", "contributors": [ "John-David Dalton (http://allyoucanleet.com/)", diff --git a/lodash.escaperegexp/README.md b/lodash.escaperegexp/README.md index 4804996d2..84a6b04fd 100644 --- a/lodash.escaperegexp/README.md +++ b/lodash.escaperegexp/README.md @@ -1,4 +1,4 @@ -# lodash.escaperegexp v4.0.1 +# lodash.escaperegexp v4.0.2 The [lodash](https://lodash.com/) method `_.escapeRegExp` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var escapeRegExp = require('lodash.escaperegexp'); ``` -See the [documentation](https://lodash.com/docs#escapeRegExp) or [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash.escaperegexp) for more details. +See the [documentation](https://lodash.com/docs#escapeRegExp) or [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash.escaperegexp) for more details. diff --git a/lodash.escaperegexp/index.js b/lodash.escaperegexp/index.js index 48b40872e..3b35fa4b9 100644 --- a/lodash.escaperegexp/index.js +++ b/lodash.escaperegexp/index.js @@ -1,5 +1,5 @@ /** - * lodash 4.0.1 (Custom Build) + * lodash 4.0.2 (Custom Build) * Build: `lodash modularize exports="npm" -o ./` * Copyright 2012-2016 The Dojo Foundation * Based on Underscore.js 1.8.3 @@ -17,8 +17,51 @@ var symbolTag = '[object Symbol]'; var reRegExpChar = /[\\^$.*+?()[\]{}|]/g, reHasRegExpChar = RegExp(reRegExpChar.source); +/** Used to determine if values are of the language type `Object`. */ +var objectTypes = { + 'function': true, + 'object': true +}; + +/** Detect free variable `exports`. */ +var freeExports = (objectTypes[typeof exports] && exports && !exports.nodeType) ? exports : null; + +/** Detect free variable `module`. */ +var freeModule = (objectTypes[typeof module] && module && !module.nodeType) ? module : null; + +/** Detect free variable `global` from Node.js. */ +var freeGlobal = checkGlobal(freeExports && freeModule && typeof global == 'object' && global); + +/** Detect free variable `self`. */ +var freeSelf = checkGlobal(objectTypes[typeof self] && self); + +/** Detect free variable `window`. */ +var freeWindow = checkGlobal(objectTypes[typeof window] && window); + +/** Detect `this` as the global object. */ +var thisGlobal = checkGlobal(objectTypes[typeof this] && this); + +/** + * Used as a reference to the global object. + * + * The `this` value is used if it's the global object to avoid Greasemonkey's + * restricted `window` object, otherwise the `window` object is used. + */ +var root = freeGlobal || ((freeWindow !== (thisGlobal && thisGlobal.window)) && freeWindow) || freeSelf || thisGlobal || Function('return this')(); + +/** + * Checks if `value` is a global object. + * + * @private + * @param {*} value The value to check. + * @returns {null|Object} Returns `value` if it's a global object, else `null`. + */ +function checkGlobal(value) { + return (value && value.Object === Object) ? value : null; +} + /** Used for built-in method references. */ -var objectProto = global.Object.prototype; +var objectProto = Object.prototype; /** * Used to resolve the [`toStringTag`](http://ecma-international.org/ecma-262/6.0/#sec-object.prototype.tostring) @@ -27,7 +70,7 @@ var objectProto = global.Object.prototype; var objectToString = objectProto.toString; /** Built-in value references. */ -var Symbol = global.Symbol; +var Symbol = root.Symbol; /** Used to convert symbols to primitives and strings. */ var symbolProto = Symbol ? Symbol.prototype : undefined, diff --git a/lodash.escaperegexp/package.json b/lodash.escaperegexp/package.json index 34408f646..70150e2a5 100644 --- a/lodash.escaperegexp/package.json +++ b/lodash.escaperegexp/package.json @@ -1,11 +1,11 @@ { "name": "lodash.escaperegexp", - "version": "4.0.1", + "version": "4.0.2", "description": "The lodash method `_.escapeRegExp` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", "license": "MIT", - "keywords": "lodash, lodash-modularized, stdlib, util, escaperegexp", + "keywords": "lodash-modularized, escaperegexp", "author": "John-David Dalton (http://allyoucanleet.com/)", "contributors": [ "John-David Dalton (http://allyoucanleet.com/)", diff --git a/lodash.every/README.md b/lodash.every/README.md index c46317c3a..89c0f9a35 100644 --- a/lodash.every/README.md +++ b/lodash.every/README.md @@ -1,4 +1,4 @@ -# lodash.every v4.0.1 +# lodash.every v4.0.2 The [lodash](https://lodash.com/) method `_.every` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var every = require('lodash.every'); ``` -See the [documentation](https://lodash.com/docs#every) or [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash.every) for more details. +See the [documentation](https://lodash.com/docs#every) or [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash.every) for more details. diff --git a/lodash.every/index.js b/lodash.every/index.js index 34729e101..ae174ca3d 100644 --- a/lodash.every/index.js +++ b/lodash.every/index.js @@ -1,5 +1,5 @@ /** - * lodash 4.0.1 (Custom Build) + * lodash 4.0.2 (Custom Build) * Build: `lodash modularize exports="npm" -o ./` * Copyright 2012-2016 The Dojo Foundation * Based on Underscore.js 1.8.3 @@ -37,6 +37,38 @@ var reEscapeChar = /\\(\\)?/g; /** Used to detect unsigned integer values. */ var reIsUint = /^(?:0|[1-9]\d*)$/; +/** Used to determine if values are of the language type `Object`. */ +var objectTypes = { + 'function': true, + 'object': true +}; + +/** Detect free variable `exports`. */ +var freeExports = (objectTypes[typeof exports] && exports && !exports.nodeType) ? exports : null; + +/** Detect free variable `module`. */ +var freeModule = (objectTypes[typeof module] && module && !module.nodeType) ? module : null; + +/** Detect free variable `global` from Node.js. */ +var freeGlobal = checkGlobal(freeExports && freeModule && typeof global == 'object' && global); + +/** Detect free variable `self`. */ +var freeSelf = checkGlobal(objectTypes[typeof self] && self); + +/** Detect free variable `window`. */ +var freeWindow = checkGlobal(objectTypes[typeof window] && window); + +/** Detect `this` as the global object. */ +var thisGlobal = checkGlobal(objectTypes[typeof this] && this); + +/** + * Used as a reference to the global object. + * + * The `this` value is used if it's the global object to avoid Greasemonkey's + * restricted `window` object, otherwise the `window` object is used. + */ +var root = freeGlobal || ((freeWindow !== (thisGlobal && thisGlobal.window)) && freeWindow) || freeSelf || thisGlobal || Function('return this')(); + /** * A specialized version of `_.every` for arrays without support for * iteratee shorthands. @@ -58,6 +90,17 @@ function arrayEvery(array, predicate) { return true; } +/** + * Checks if `value` is a global object. + * + * @private + * @param {*} value The value to check. + * @returns {null|Object} Returns `value` if it's a global object, else `null`. + */ +function checkGlobal(value) { + return (value && value.Object === Object) ? value : null; +} + /** * Checks if `value` is a valid array-like index. * @@ -73,7 +116,7 @@ function isIndex(value, length) { } /** Used for built-in method references. */ -var objectProto = global.Object.prototype; +var objectProto = Object.prototype; /** * Used to resolve the [`toStringTag`](http://ecma-international.org/ecma-262/6.0/#sec-object.prototype.tostring) @@ -82,7 +125,7 @@ var objectProto = global.Object.prototype; var objectToString = objectProto.toString; /** Built-in value references. */ -var Symbol = global.Symbol; +var Symbol = root.Symbol; /** Used to convert symbols to primitives and strings. */ var symbolProto = Symbol ? Symbol.prototype : undefined, @@ -346,15 +389,15 @@ function stringToPath(string) { * { 'user': 'fred', 'active': false } * ]; * - * // using the `_.matches` iteratee shorthand + * // The `_.matches` iteratee shorthand. * _.every(users, { 'user': 'barney', 'active': false }); * // => false * - * // using the `_.matchesProperty` iteratee shorthand + * // The `_.matchesProperty` iteratee shorthand. * _.every(users, ['active', false]); * // => true * - * // using the `_.property` iteratee shorthand + * // The `_.property` iteratee shorthand. * _.every(users, 'active'); * // => false */ diff --git a/lodash.every/package.json b/lodash.every/package.json index f01f47a84..23ec43673 100644 --- a/lodash.every/package.json +++ b/lodash.every/package.json @@ -1,11 +1,11 @@ { "name": "lodash.every", - "version": "4.0.1", + "version": "4.0.2", "description": "The lodash method `_.every` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", "license": "MIT", - "keywords": "lodash, lodash-modularized, stdlib, util, every", + "keywords": "lodash-modularized, every", "author": "John-David Dalton (http://allyoucanleet.com/)", "contributors": [ "John-David Dalton (http://allyoucanleet.com/)", diff --git a/lodash.filter/README.md b/lodash.filter/README.md index 39cd3f605..8514982f5 100644 --- a/lodash.filter/README.md +++ b/lodash.filter/README.md @@ -1,4 +1,4 @@ -# lodash.filter v4.0.1 +# lodash.filter v4.0.2 The [lodash](https://lodash.com/) method `_.filter` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var filter = require('lodash.filter'); ``` -See the [documentation](https://lodash.com/docs#filter) or [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash.filter) for more details. +See the [documentation](https://lodash.com/docs#filter) or [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash.filter) for more details. diff --git a/lodash.filter/index.js b/lodash.filter/index.js index 03b56bc0d..c088f3fb1 100644 --- a/lodash.filter/index.js +++ b/lodash.filter/index.js @@ -1,5 +1,5 @@ /** - * lodash 4.0.1 (Custom Build) + * lodash 4.0.2 (Custom Build) * Build: `lodash modularize exports="npm" -o ./` * Copyright 2012-2016 The Dojo Foundation * Based on Underscore.js 1.8.3 @@ -32,8 +32,51 @@ var reIsDeepProp = /\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/, /** Used to match backslashes in property paths. */ var reEscapeChar = /\\(\\)?/g; +/** Used to determine if values are of the language type `Object`. */ +var objectTypes = { + 'function': true, + 'object': true +}; + +/** Detect free variable `exports`. */ +var freeExports = (objectTypes[typeof exports] && exports && !exports.nodeType) ? exports : null; + +/** Detect free variable `module`. */ +var freeModule = (objectTypes[typeof module] && module && !module.nodeType) ? module : null; + +/** Detect free variable `global` from Node.js. */ +var freeGlobal = checkGlobal(freeExports && freeModule && typeof global == 'object' && global); + +/** Detect free variable `self`. */ +var freeSelf = checkGlobal(objectTypes[typeof self] && self); + +/** Detect free variable `window`. */ +var freeWindow = checkGlobal(objectTypes[typeof window] && window); + +/** Detect `this` as the global object. */ +var thisGlobal = checkGlobal(objectTypes[typeof this] && this); + +/** + * Used as a reference to the global object. + * + * The `this` value is used if it's the global object to avoid Greasemonkey's + * restricted `window` object, otherwise the `window` object is used. + */ +var root = freeGlobal || ((freeWindow !== (thisGlobal && thisGlobal.window)) && freeWindow) || freeSelf || thisGlobal || Function('return this')(); + +/** + * Checks if `value` is a global object. + * + * @private + * @param {*} value The value to check. + * @returns {null|Object} Returns `value` if it's a global object, else `null`. + */ +function checkGlobal(value) { + return (value && value.Object === Object) ? value : null; +} + /** Used for built-in method references. */ -var objectProto = global.Object.prototype; +var objectProto = Object.prototype; /** * Used to resolve the [`toStringTag`](http://ecma-international.org/ecma-262/6.0/#sec-object.prototype.tostring) @@ -42,7 +85,7 @@ var objectProto = global.Object.prototype; var objectToString = objectProto.toString; /** Built-in value references. */ -var Symbol = global.Symbol; +var Symbol = root.Symbol; /** Used to convert symbols to primitives and strings. */ var symbolProto = Symbol ? Symbol.prototype : undefined, @@ -254,15 +297,15 @@ function stringToPath(string) { * _.filter(users, function(o) { return !o.active; }); * // => objects for ['fred'] * - * // using the `_.matches` iteratee shorthand + * // The `_.matches` iteratee shorthand. * _.filter(users, { 'age': 36, 'active': true }); * // => objects for ['barney'] * - * // using the `_.matchesProperty` iteratee shorthand + * // The `_.matchesProperty` iteratee shorthand. * _.filter(users, ['active', false]); * // => objects for ['fred'] * - * // using the `_.property` iteratee shorthand + * // The `_.property` iteratee shorthand. * _.filter(users, 'active'); * // => objects for ['barney'] */ diff --git a/lodash.filter/package.json b/lodash.filter/package.json index 15c2eed4b..66b17d6ea 100644 --- a/lodash.filter/package.json +++ b/lodash.filter/package.json @@ -1,11 +1,11 @@ { "name": "lodash.filter", - "version": "4.0.1", + "version": "4.0.2", "description": "The lodash method `_.filter` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", "license": "MIT", - "keywords": "lodash, lodash-modularized, stdlib, util, filter", + "keywords": "lodash-modularized, filter", "author": "John-David Dalton (http://allyoucanleet.com/)", "contributors": [ "John-David Dalton (http://allyoucanleet.com/)", diff --git a/lodash.find/README.md b/lodash.find/README.md index e69eada1a..8caf9aa77 100644 --- a/lodash.find/README.md +++ b/lodash.find/README.md @@ -1,4 +1,4 @@ -# lodash.find v4.0.1 +# lodash.find v4.0.2 The [lodash](https://lodash.com/) method `_.find` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var find = require('lodash.find'); ``` -See the [documentation](https://lodash.com/docs#find) or [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash.find) for more details. +See the [documentation](https://lodash.com/docs#find) or [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash.find) for more details. diff --git a/lodash.find/index.js b/lodash.find/index.js index 04215f6c5..f91febc50 100644 --- a/lodash.find/index.js +++ b/lodash.find/index.js @@ -1,5 +1,5 @@ /** - * lodash 4.0.1 (Custom Build) + * lodash 4.0.2 (Custom Build) * Build: `lodash modularize exports="npm" -o ./` * Copyright 2012-2016 The Dojo Foundation * Based on Underscore.js 1.8.3 @@ -33,8 +33,51 @@ var reIsDeepProp = /\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/, /** Used to match backslashes in property paths. */ var reEscapeChar = /\\(\\)?/g; +/** Used to determine if values are of the language type `Object`. */ +var objectTypes = { + 'function': true, + 'object': true +}; + +/** Detect free variable `exports`. */ +var freeExports = (objectTypes[typeof exports] && exports && !exports.nodeType) ? exports : null; + +/** Detect free variable `module`. */ +var freeModule = (objectTypes[typeof module] && module && !module.nodeType) ? module : null; + +/** Detect free variable `global` from Node.js. */ +var freeGlobal = checkGlobal(freeExports && freeModule && typeof global == 'object' && global); + +/** Detect free variable `self`. */ +var freeSelf = checkGlobal(objectTypes[typeof self] && self); + +/** Detect free variable `window`. */ +var freeWindow = checkGlobal(objectTypes[typeof window] && window); + +/** Detect `this` as the global object. */ +var thisGlobal = checkGlobal(objectTypes[typeof this] && this); + +/** + * Used as a reference to the global object. + * + * The `this` value is used if it's the global object to avoid Greasemonkey's + * restricted `window` object, otherwise the `window` object is used. + */ +var root = freeGlobal || ((freeWindow !== (thisGlobal && thisGlobal.window)) && freeWindow) || freeSelf || thisGlobal || Function('return this')(); + +/** + * Checks if `value` is a global object. + * + * @private + * @param {*} value The value to check. + * @returns {null|Object} Returns `value` if it's a global object, else `null`. + */ +function checkGlobal(value) { + return (value && value.Object === Object) ? value : null; +} + /** Used for built-in method references. */ -var objectProto = global.Object.prototype; +var objectProto = Object.prototype; /** * Used to resolve the [`toStringTag`](http://ecma-international.org/ecma-262/6.0/#sec-object.prototype.tostring) @@ -43,7 +86,7 @@ var objectProto = global.Object.prototype; var objectToString = objectProto.toString; /** Built-in value references. */ -var Symbol = global.Symbol; +var Symbol = root.Symbol; /** Used to convert symbols to primitives and strings. */ var symbolProto = Symbol ? Symbol.prototype : undefined, @@ -256,15 +299,15 @@ function stringToPath(string) { * _.find(users, function(o) { return o.age < 40; }); * // => object for 'barney' * - * // using the `_.matches` iteratee shorthand + * // The `_.matches` iteratee shorthand. * _.find(users, { 'age': 1, 'active': true }); * // => object for 'pebbles' * - * // using the `_.matchesProperty` iteratee shorthand + * // The `_.matchesProperty` iteratee shorthand. * _.find(users, ['active', false]); * // => object for 'fred' * - * // using the `_.property` iteratee shorthand + * // The `_.property` iteratee shorthand. * _.find(users, 'active'); * // => object for 'barney' */ diff --git a/lodash.find/package.json b/lodash.find/package.json index 633c0dbc6..6bdc7e63a 100644 --- a/lodash.find/package.json +++ b/lodash.find/package.json @@ -1,11 +1,11 @@ { "name": "lodash.find", - "version": "4.0.1", + "version": "4.0.2", "description": "The lodash method `_.find` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", "license": "MIT", - "keywords": "lodash, lodash-modularized, stdlib, util, find", + "keywords": "lodash-modularized, find", "author": "John-David Dalton (http://allyoucanleet.com/)", "contributors": [ "John-David Dalton (http://allyoucanleet.com/)", diff --git a/lodash.findindex/README.md b/lodash.findindex/README.md index 7e549c103..038b59568 100644 --- a/lodash.findindex/README.md +++ b/lodash.findindex/README.md @@ -1,4 +1,4 @@ -# lodash.findindex v4.0.1 +# lodash.findindex v4.0.2 The [lodash](https://lodash.com/) method `_.findIndex` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var findIndex = require('lodash.findindex'); ``` -See the [documentation](https://lodash.com/docs#findIndex) or [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash.findindex) for more details. +See the [documentation](https://lodash.com/docs#findIndex) or [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash.findindex) for more details. diff --git a/lodash.findindex/index.js b/lodash.findindex/index.js index 592bf30fd..49fbe9bdc 100644 --- a/lodash.findindex/index.js +++ b/lodash.findindex/index.js @@ -1,5 +1,5 @@ /** - * lodash 4.0.1 (Custom Build) + * lodash 4.0.2 (Custom Build) * Build: `lodash modularize exports="npm" -o ./` * Copyright 2012-2016 The Dojo Foundation * Based on Underscore.js 1.8.3 @@ -31,8 +31,51 @@ var reIsDeepProp = /\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/, /** Used to match backslashes in property paths. */ var reEscapeChar = /\\(\\)?/g; +/** Used to determine if values are of the language type `Object`. */ +var objectTypes = { + 'function': true, + 'object': true +}; + +/** Detect free variable `exports`. */ +var freeExports = (objectTypes[typeof exports] && exports && !exports.nodeType) ? exports : null; + +/** Detect free variable `module`. */ +var freeModule = (objectTypes[typeof module] && module && !module.nodeType) ? module : null; + +/** Detect free variable `global` from Node.js. */ +var freeGlobal = checkGlobal(freeExports && freeModule && typeof global == 'object' && global); + +/** Detect free variable `self`. */ +var freeSelf = checkGlobal(objectTypes[typeof self] && self); + +/** Detect free variable `window`. */ +var freeWindow = checkGlobal(objectTypes[typeof window] && window); + +/** Detect `this` as the global object. */ +var thisGlobal = checkGlobal(objectTypes[typeof this] && this); + +/** + * Used as a reference to the global object. + * + * The `this` value is used if it's the global object to avoid Greasemonkey's + * restricted `window` object, otherwise the `window` object is used. + */ +var root = freeGlobal || ((freeWindow !== (thisGlobal && thisGlobal.window)) && freeWindow) || freeSelf || thisGlobal || Function('return this')(); + +/** + * Checks if `value` is a global object. + * + * @private + * @param {*} value The value to check. + * @returns {null|Object} Returns `value` if it's a global object, else `null`. + */ +function checkGlobal(value) { + return (value && value.Object === Object) ? value : null; +} + /** Used for built-in method references. */ -var objectProto = global.Object.prototype; +var objectProto = Object.prototype; /** * Used to resolve the [`toStringTag`](http://ecma-international.org/ecma-262/6.0/#sec-object.prototype.tostring) @@ -41,7 +84,7 @@ var objectProto = global.Object.prototype; var objectToString = objectProto.toString; /** Built-in value references. */ -var Symbol = global.Symbol; +var Symbol = root.Symbol; /** Used to convert symbols to primitives and strings. */ var symbolProto = Symbol ? Symbol.prototype : undefined, @@ -253,15 +296,15 @@ function stringToPath(string) { * _.findIndex(users, function(o) { return o.user == 'barney'; }); * // => 0 * - * // using the `_.matches` iteratee shorthand + * // The `_.matches` iteratee shorthand. * _.findIndex(users, { 'user': 'fred', 'active': false }); * // => 1 * - * // using the `_.matchesProperty` iteratee shorthand + * // The `_.matchesProperty` iteratee shorthand. * _.findIndex(users, ['active', false]); * // => 0 * - * // using the `_.property` iteratee shorthand + * // The `_.property` iteratee shorthand. * _.findIndex(users, 'active'); * // => 2 */ diff --git a/lodash.findindex/package.json b/lodash.findindex/package.json index 8f3026884..bea9dd9bf 100644 --- a/lodash.findindex/package.json +++ b/lodash.findindex/package.json @@ -1,11 +1,11 @@ { "name": "lodash.findindex", - "version": "4.0.1", + "version": "4.0.2", "description": "The lodash method `_.findIndex` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", "license": "MIT", - "keywords": "lodash, lodash-modularized, stdlib, util, findindex", + "keywords": "lodash-modularized, findindex", "author": "John-David Dalton (http://allyoucanleet.com/)", "contributors": [ "John-David Dalton (http://allyoucanleet.com/)", diff --git a/lodash.findkey/README.md b/lodash.findkey/README.md index 832c69995..122382ec0 100644 --- a/lodash.findkey/README.md +++ b/lodash.findkey/README.md @@ -1,4 +1,4 @@ -# lodash.findkey v4.0.1 +# lodash.findkey v4.0.2 The [lodash](https://lodash.com/) method `_.findKey` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var findKey = require('lodash.findkey'); ``` -See the [documentation](https://lodash.com/docs#findKey) or [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash.findkey) for more details. +See the [documentation](https://lodash.com/docs#findKey) or [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash.findkey) for more details. diff --git a/lodash.findkey/index.js b/lodash.findkey/index.js index abbd432aa..ea8f9ce89 100644 --- a/lodash.findkey/index.js +++ b/lodash.findkey/index.js @@ -1,5 +1,5 @@ /** - * lodash 4.0.1 (Custom Build) + * lodash 4.0.2 (Custom Build) * Build: `lodash modularize exports="npm" -o ./` * Copyright 2012-2016 The Dojo Foundation * Based on Underscore.js 1.8.3 @@ -33,8 +33,51 @@ var reIsDeepProp = /\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/, /** Used to match backslashes in property paths. */ var reEscapeChar = /\\(\\)?/g; +/** Used to determine if values are of the language type `Object`. */ +var objectTypes = { + 'function': true, + 'object': true +}; + +/** Detect free variable `exports`. */ +var freeExports = (objectTypes[typeof exports] && exports && !exports.nodeType) ? exports : null; + +/** Detect free variable `module`. */ +var freeModule = (objectTypes[typeof module] && module && !module.nodeType) ? module : null; + +/** Detect free variable `global` from Node.js. */ +var freeGlobal = checkGlobal(freeExports && freeModule && typeof global == 'object' && global); + +/** Detect free variable `self`. */ +var freeSelf = checkGlobal(objectTypes[typeof self] && self); + +/** Detect free variable `window`. */ +var freeWindow = checkGlobal(objectTypes[typeof window] && window); + +/** Detect `this` as the global object. */ +var thisGlobal = checkGlobal(objectTypes[typeof this] && this); + +/** + * Used as a reference to the global object. + * + * The `this` value is used if it's the global object to avoid Greasemonkey's + * restricted `window` object, otherwise the `window` object is used. + */ +var root = freeGlobal || ((freeWindow !== (thisGlobal && thisGlobal.window)) && freeWindow) || freeSelf || thisGlobal || Function('return this')(); + +/** + * Checks if `value` is a global object. + * + * @private + * @param {*} value The value to check. + * @returns {null|Object} Returns `value` if it's a global object, else `null`. + */ +function checkGlobal(value) { + return (value && value.Object === Object) ? value : null; +} + /** Used for built-in method references. */ -var objectProto = global.Object.prototype; +var objectProto = Object.prototype; /** * Used to resolve the [`toStringTag`](http://ecma-international.org/ecma-262/6.0/#sec-object.prototype.tostring) @@ -43,7 +86,7 @@ var objectProto = global.Object.prototype; var objectToString = objectProto.toString; /** Built-in value references. */ -var Symbol = global.Symbol; +var Symbol = root.Symbol; /** Used to convert symbols to primitives and strings. */ var symbolProto = Symbol ? Symbol.prototype : undefined, @@ -403,15 +446,15 @@ function toString(value) { * _.findKey(users, function(o) { return o.age < 40; }); * // => 'barney' (iteration order is not guaranteed) * - * // using the `_.matches` iteratee shorthand + * // The `_.matches` iteratee shorthand. * _.findKey(users, { 'age': 1, 'active': true }); * // => 'pebbles' * - * // using the `_.matchesProperty` iteratee shorthand + * // The `_.matchesProperty` iteratee shorthand. * _.findKey(users, ['active', false]); * // => 'fred' * - * // using the `_.property` iteratee shorthand + * // The `_.property` iteratee shorthand. * _.findKey(users, 'active'); * // => 'barney' */ diff --git a/lodash.findkey/package.json b/lodash.findkey/package.json index a23862b22..5e65d0b4a 100644 --- a/lodash.findkey/package.json +++ b/lodash.findkey/package.json @@ -1,11 +1,11 @@ { "name": "lodash.findkey", - "version": "4.0.1", + "version": "4.0.2", "description": "The lodash method `_.findKey` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", "license": "MIT", - "keywords": "lodash, lodash-modularized, stdlib, util, findkey", + "keywords": "lodash-modularized, findkey", "author": "John-David Dalton (http://allyoucanleet.com/)", "contributors": [ "John-David Dalton (http://allyoucanleet.com/)", diff --git a/lodash.findlast/README.md b/lodash.findlast/README.md index 2dd8610ed..ff0390c0f 100644 --- a/lodash.findlast/README.md +++ b/lodash.findlast/README.md @@ -1,4 +1,4 @@ -# lodash.findlast v4.0.1 +# lodash.findlast v4.0.2 The [lodash](https://lodash.com/) method `_.findLast` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var findLast = require('lodash.findlast'); ``` -See the [documentation](https://lodash.com/docs#findLast) or [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash.findlast) for more details. +See the [documentation](https://lodash.com/docs#findLast) or [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash.findlast) for more details. diff --git a/lodash.findlast/index.js b/lodash.findlast/index.js index cc0d4f387..6f486be68 100644 --- a/lodash.findlast/index.js +++ b/lodash.findlast/index.js @@ -1,5 +1,5 @@ /** - * lodash 4.0.1 (Custom Build) + * lodash 4.0.2 (Custom Build) * Build: `lodash modularize exports="npm" -o ./` * Copyright 2012-2016 The Dojo Foundation * Based on Underscore.js 1.8.3 @@ -33,8 +33,51 @@ var reIsDeepProp = /\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/, /** Used to match backslashes in property paths. */ var reEscapeChar = /\\(\\)?/g; +/** Used to determine if values are of the language type `Object`. */ +var objectTypes = { + 'function': true, + 'object': true +}; + +/** Detect free variable `exports`. */ +var freeExports = (objectTypes[typeof exports] && exports && !exports.nodeType) ? exports : null; + +/** Detect free variable `module`. */ +var freeModule = (objectTypes[typeof module] && module && !module.nodeType) ? module : null; + +/** Detect free variable `global` from Node.js. */ +var freeGlobal = checkGlobal(freeExports && freeModule && typeof global == 'object' && global); + +/** Detect free variable `self`. */ +var freeSelf = checkGlobal(objectTypes[typeof self] && self); + +/** Detect free variable `window`. */ +var freeWindow = checkGlobal(objectTypes[typeof window] && window); + +/** Detect `this` as the global object. */ +var thisGlobal = checkGlobal(objectTypes[typeof this] && this); + +/** + * Used as a reference to the global object. + * + * The `this` value is used if it's the global object to avoid Greasemonkey's + * restricted `window` object, otherwise the `window` object is used. + */ +var root = freeGlobal || ((freeWindow !== (thisGlobal && thisGlobal.window)) && freeWindow) || freeSelf || thisGlobal || Function('return this')(); + +/** + * Checks if `value` is a global object. + * + * @private + * @param {*} value The value to check. + * @returns {null|Object} Returns `value` if it's a global object, else `null`. + */ +function checkGlobal(value) { + return (value && value.Object === Object) ? value : null; +} + /** Used for built-in method references. */ -var objectProto = global.Object.prototype; +var objectProto = Object.prototype; /** * Used to resolve the [`toStringTag`](http://ecma-international.org/ecma-262/6.0/#sec-object.prototype.tostring) @@ -43,7 +86,7 @@ var objectProto = global.Object.prototype; var objectToString = objectProto.toString; /** Built-in value references. */ -var Symbol = global.Symbol; +var Symbol = root.Symbol; /** Used to convert symbols to primitives and strings. */ var symbolProto = Symbol ? Symbol.prototype : undefined, diff --git a/lodash.findlast/package.json b/lodash.findlast/package.json index 5c4445719..698c29d1a 100644 --- a/lodash.findlast/package.json +++ b/lodash.findlast/package.json @@ -1,11 +1,11 @@ { "name": "lodash.findlast", - "version": "4.0.1", + "version": "4.0.2", "description": "The lodash method `_.findLast` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", "license": "MIT", - "keywords": "lodash, lodash-modularized, stdlib, util, findlast", + "keywords": "lodash-modularized, findlast", "author": "John-David Dalton (http://allyoucanleet.com/)", "contributors": [ "John-David Dalton (http://allyoucanleet.com/)", diff --git a/lodash.findlastindex/README.md b/lodash.findlastindex/README.md index b517c1d10..f28c74041 100644 --- a/lodash.findlastindex/README.md +++ b/lodash.findlastindex/README.md @@ -1,4 +1,4 @@ -# lodash.findlastindex v4.0.1 +# lodash.findlastindex v4.0.2 The [lodash](https://lodash.com/) method `_.findLastIndex` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var findLastIndex = require('lodash.findlastindex'); ``` -See the [documentation](https://lodash.com/docs#findLastIndex) or [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash.findlastindex) for more details. +See the [documentation](https://lodash.com/docs#findLastIndex) or [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash.findlastindex) for more details. diff --git a/lodash.findlastindex/index.js b/lodash.findlastindex/index.js index 0accc4958..cc84259e1 100644 --- a/lodash.findlastindex/index.js +++ b/lodash.findlastindex/index.js @@ -1,5 +1,5 @@ /** - * lodash 4.0.1 (Custom Build) + * lodash 4.0.2 (Custom Build) * Build: `lodash modularize exports="npm" -o ./` * Copyright 2012-2016 The Dojo Foundation * Based on Underscore.js 1.8.3 @@ -31,8 +31,51 @@ var reIsDeepProp = /\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/, /** Used to match backslashes in property paths. */ var reEscapeChar = /\\(\\)?/g; +/** Used to determine if values are of the language type `Object`. */ +var objectTypes = { + 'function': true, + 'object': true +}; + +/** Detect free variable `exports`. */ +var freeExports = (objectTypes[typeof exports] && exports && !exports.nodeType) ? exports : null; + +/** Detect free variable `module`. */ +var freeModule = (objectTypes[typeof module] && module && !module.nodeType) ? module : null; + +/** Detect free variable `global` from Node.js. */ +var freeGlobal = checkGlobal(freeExports && freeModule && typeof global == 'object' && global); + +/** Detect free variable `self`. */ +var freeSelf = checkGlobal(objectTypes[typeof self] && self); + +/** Detect free variable `window`. */ +var freeWindow = checkGlobal(objectTypes[typeof window] && window); + +/** Detect `this` as the global object. */ +var thisGlobal = checkGlobal(objectTypes[typeof this] && this); + +/** + * Used as a reference to the global object. + * + * The `this` value is used if it's the global object to avoid Greasemonkey's + * restricted `window` object, otherwise the `window` object is used. + */ +var root = freeGlobal || ((freeWindow !== (thisGlobal && thisGlobal.window)) && freeWindow) || freeSelf || thisGlobal || Function('return this')(); + +/** + * Checks if `value` is a global object. + * + * @private + * @param {*} value The value to check. + * @returns {null|Object} Returns `value` if it's a global object, else `null`. + */ +function checkGlobal(value) { + return (value && value.Object === Object) ? value : null; +} + /** Used for built-in method references. */ -var objectProto = global.Object.prototype; +var objectProto = Object.prototype; /** * Used to resolve the [`toStringTag`](http://ecma-international.org/ecma-262/6.0/#sec-object.prototype.tostring) @@ -41,7 +84,7 @@ var objectProto = global.Object.prototype; var objectToString = objectProto.toString; /** Built-in value references. */ -var Symbol = global.Symbol; +var Symbol = root.Symbol; /** Used to convert symbols to primitives and strings. */ var symbolProto = Symbol ? Symbol.prototype : undefined, @@ -253,15 +296,15 @@ function stringToPath(string) { * _.findLastIndex(users, function(o) { return o.user == 'pebbles'; }); * // => 2 * - * // using the `_.matches` iteratee shorthand + * // The `_.matches` iteratee shorthand. * _.findLastIndex(users, { 'user': 'barney', 'active': true }); * // => 0 * - * // using the `_.matchesProperty` iteratee shorthand + * // The `_.matchesProperty` iteratee shorthand. * _.findLastIndex(users, ['active', false]); * // => 2 * - * // using the `_.property` iteratee shorthand + * // The `_.property` iteratee shorthand. * _.findLastIndex(users, 'active'); * // => 0 */ diff --git a/lodash.findlastindex/package.json b/lodash.findlastindex/package.json index 14b4ea5fb..48414ff26 100644 --- a/lodash.findlastindex/package.json +++ b/lodash.findlastindex/package.json @@ -1,11 +1,11 @@ { "name": "lodash.findlastindex", - "version": "4.0.1", + "version": "4.0.2", "description": "The lodash method `_.findLastIndex` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", "license": "MIT", - "keywords": "lodash, lodash-modularized, stdlib, util, findlastindex", + "keywords": "lodash-modularized, findlastindex", "author": "John-David Dalton (http://allyoucanleet.com/)", "contributors": [ "John-David Dalton (http://allyoucanleet.com/)", diff --git a/lodash.findlastkey/README.md b/lodash.findlastkey/README.md index 80a29c40c..1754a159c 100644 --- a/lodash.findlastkey/README.md +++ b/lodash.findlastkey/README.md @@ -1,4 +1,4 @@ -# lodash.findlastkey v4.0.1 +# lodash.findlastkey v4.0.2 The [lodash](https://lodash.com/) method `_.findLastKey` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var findLastKey = require('lodash.findlastkey'); ``` -See the [documentation](https://lodash.com/docs#findLastKey) or [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash.findlastkey) for more details. +See the [documentation](https://lodash.com/docs#findLastKey) or [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash.findlastkey) for more details. diff --git a/lodash.findlastkey/index.js b/lodash.findlastkey/index.js index e2ac18024..8e2294ad4 100644 --- a/lodash.findlastkey/index.js +++ b/lodash.findlastkey/index.js @@ -1,5 +1,5 @@ /** - * lodash 4.0.1 (Custom Build) + * lodash 4.0.2 (Custom Build) * Build: `lodash modularize exports="npm" -o ./` * Copyright 2012-2016 The Dojo Foundation * Based on Underscore.js 1.8.3 @@ -32,8 +32,51 @@ var reIsDeepProp = /\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/, /** Used to match backslashes in property paths. */ var reEscapeChar = /\\(\\)?/g; +/** Used to determine if values are of the language type `Object`. */ +var objectTypes = { + 'function': true, + 'object': true +}; + +/** Detect free variable `exports`. */ +var freeExports = (objectTypes[typeof exports] && exports && !exports.nodeType) ? exports : null; + +/** Detect free variable `module`. */ +var freeModule = (objectTypes[typeof module] && module && !module.nodeType) ? module : null; + +/** Detect free variable `global` from Node.js. */ +var freeGlobal = checkGlobal(freeExports && freeModule && typeof global == 'object' && global); + +/** Detect free variable `self`. */ +var freeSelf = checkGlobal(objectTypes[typeof self] && self); + +/** Detect free variable `window`. */ +var freeWindow = checkGlobal(objectTypes[typeof window] && window); + +/** Detect `this` as the global object. */ +var thisGlobal = checkGlobal(objectTypes[typeof this] && this); + +/** + * Used as a reference to the global object. + * + * The `this` value is used if it's the global object to avoid Greasemonkey's + * restricted `window` object, otherwise the `window` object is used. + */ +var root = freeGlobal || ((freeWindow !== (thisGlobal && thisGlobal.window)) && freeWindow) || freeSelf || thisGlobal || Function('return this')(); + +/** + * Checks if `value` is a global object. + * + * @private + * @param {*} value The value to check. + * @returns {null|Object} Returns `value` if it's a global object, else `null`. + */ +function checkGlobal(value) { + return (value && value.Object === Object) ? value : null; +} + /** Used for built-in method references. */ -var objectProto = global.Object.prototype; +var objectProto = Object.prototype; /** * Used to resolve the [`toStringTag`](http://ecma-international.org/ecma-262/6.0/#sec-object.prototype.tostring) @@ -42,7 +85,7 @@ var objectProto = global.Object.prototype; var objectToString = objectProto.toString; /** Built-in value references. */ -var Symbol = global.Symbol; +var Symbol = root.Symbol; /** Used to convert symbols to primitives and strings. */ var symbolProto = Symbol ? Symbol.prototype : undefined, @@ -438,15 +481,15 @@ function toString(value) { * _.findLastKey(users, function(o) { return o.age < 40; }); * // => returns 'pebbles' assuming `_.findKey` returns 'barney' * - * // using the `_.matches` iteratee shorthand + * // The `_.matches` iteratee shorthand. * _.findLastKey(users, { 'age': 36, 'active': true }); * // => 'barney' * - * // using the `_.matchesProperty` iteratee shorthand + * // The `_.matchesProperty` iteratee shorthand. * _.findLastKey(users, ['active', false]); * // => 'fred' * - * // using the `_.property` iteratee shorthand + * // The `_.property` iteratee shorthand. * _.findLastKey(users, 'active'); * // => 'pebbles' */ diff --git a/lodash.findlastkey/package.json b/lodash.findlastkey/package.json index 301d62afa..dbcd5c09d 100644 --- a/lodash.findlastkey/package.json +++ b/lodash.findlastkey/package.json @@ -1,11 +1,11 @@ { "name": "lodash.findlastkey", - "version": "4.0.1", + "version": "4.0.2", "description": "The lodash method `_.findLastKey` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", "license": "MIT", - "keywords": "lodash, lodash-modularized, stdlib, util, findlastkey", + "keywords": "lodash-modularized, findlastkey", "author": "John-David Dalton (http://allyoucanleet.com/)", "contributors": [ "John-David Dalton (http://allyoucanleet.com/)", diff --git a/lodash.floor/README.md b/lodash.floor/README.md index 46cd36384..f8b1d26d5 100644 --- a/lodash.floor/README.md +++ b/lodash.floor/README.md @@ -1,4 +1,4 @@ -# lodash.floor v4.0.1 +# lodash.floor v4.0.2 The [lodash](https://lodash.com/) method `_.floor` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var floor = require('lodash.floor'); ``` -See the [documentation](https://lodash.com/docs#floor) or [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash.floor) for more details. +See the [documentation](https://lodash.com/docs#floor) or [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash.floor) for more details. diff --git a/lodash.floor/index.js b/lodash.floor/index.js index 72bd7bf10..b25bbe951 100644 --- a/lodash.floor/index.js +++ b/lodash.floor/index.js @@ -1,5 +1,5 @@ /** - * lodash 4.0.1 (Custom Build) + * lodash (Custom Build) * Build: `lodash modularize exports="npm" -o ./` * Copyright jQuery Foundation and other contributors * Released under MIT license @@ -175,6 +175,41 @@ function isSymbol(value) { (isObjectLike(value) && objectToString.call(value) == symbolTag); } +/** + * Converts `value` to a finite number. + * + * @static + * @memberOf _ + * @since 4.12.0 + * @category Lang + * @param {*} value The value to convert. + * @returns {number} Returns the converted number. + * @example + * + * _.toFinite(3.2); + * // => 3.2 + * + * _.toFinite(Number.MIN_VALUE); + * // => 5e-324 + * + * _.toFinite(Infinity); + * // => 1.7976931348623157e+308 + * + * _.toFinite('3.2'); + * // => 3.2 + */ +function toFinite(value) { + if (!value) { + return value === 0 ? value : 0; + } + value = toNumber(value); + if (value === INFINITY || value === -INFINITY) { + var sign = (value < 0 ? -1 : 1); + return sign * MAX_INTEGER; + } + return value === value ? value : 0; +} + /** * Converts `value` to an integer. * @@ -189,7 +224,7 @@ function isSymbol(value) { * @returns {number} Returns the converted integer. * @example * - * _.toInteger(3); + * _.toInteger(3.2); * // => 3 * * _.toInteger(Number.MIN_VALUE); @@ -198,20 +233,14 @@ function isSymbol(value) { * _.toInteger(Infinity); * // => 1.7976931348623157e+308 * - * _.toInteger('3'); + * _.toInteger('3.2'); * // => 3 */ function toInteger(value) { - if (!value) { - return value === 0 ? value : 0; - } - value = toNumber(value); - if (value === INFINITY || value === -INFINITY) { - var sign = (value < 0 ? -1 : 1); - return sign * MAX_INTEGER; - } - var remainder = value % 1; - return value === value ? (remainder ? value - remainder : value) : 0; + var result = toFinite(value), + remainder = result % 1; + + return result === result ? (remainder ? result - remainder : result) : 0; } /** @@ -225,8 +254,8 @@ function toInteger(value) { * @returns {number} Returns the number. * @example * - * _.toNumber(3); - * // => 3 + * _.toNumber(3.2); + * // => 3.2 * * _.toNumber(Number.MIN_VALUE); * // => 5e-324 @@ -234,8 +263,8 @@ function toInteger(value) { * _.toNumber(Infinity); * // => Infinity * - * _.toNumber('3'); - * // => 3 + * _.toNumber('3.2'); + * // => 3.2 */ function toNumber(value) { if (typeof value == 'number') { diff --git a/lodash.floor/package.json b/lodash.floor/package.json index e8f56174e..2c60f5ecc 100644 --- a/lodash.floor/package.json +++ b/lodash.floor/package.json @@ -1,6 +1,6 @@ { "name": "lodash.floor", - "version": "4.0.1", + "version": "4.0.2", "description": "The lodash method `_.floor` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", diff --git a/lodash.foreachright/README.md b/lodash.foreachright/README.md index 4328790f8..64789164e 100644 --- a/lodash.foreachright/README.md +++ b/lodash.foreachright/README.md @@ -1,4 +1,4 @@ -# lodash.foreachright v4.0.1 +# lodash.foreachright v4.0.2 The [lodash](https://lodash.com/) method `_.forEachRight` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var forEachRight = require('lodash.foreachright'); ``` -See the [documentation](https://lodash.com/docs#forEachRight) or [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash.foreachright) for more details. +See the [documentation](https://lodash.com/docs#forEachRight) or [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash.foreachright) for more details. diff --git a/lodash.foreachright/index.js b/lodash.foreachright/index.js index 56fdbc256..005dcc65f 100644 --- a/lodash.foreachright/index.js +++ b/lodash.foreachright/index.js @@ -1,5 +1,5 @@ /** - * lodash 4.0.1 (Custom Build) + * lodash 4.0.2 (Custom Build) * Build: `lodash modularize exports="npm" -o ./` * Copyright 2012-2016 The Dojo Foundation * Based on Underscore.js 1.8.3 diff --git a/lodash.foreachright/package.json b/lodash.foreachright/package.json index 00315c171..adc8d01e1 100644 --- a/lodash.foreachright/package.json +++ b/lodash.foreachright/package.json @@ -1,6 +1,6 @@ { "name": "lodash.foreachright", - "version": "4.0.1", + "version": "4.0.2", "description": "The lodash method `_.forEachRight` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", @@ -9,12 +9,12 @@ "author": "John-David Dalton (http://allyoucanleet.com/)", "contributors": [ "John-David Dalton (http://allyoucanleet.com/)", - "Blaine Bublitz (https://github.com/phated)", + "Blaine Bublitz (https://github.com/phated)", "Mathias Bynens (https://mathiasbynens.be/)" ], "repository": "lodash/lodash", "scripts": { "test": "echo \"See https://travis-ci.org/lodash/lodash-cli for testing details.\"" }, "dependencies": { - "lodash._baseeachright": "^4.0.0" + "lodash._baseeachright": "~4.1.0" } } diff --git a/lodash.forin/README.md b/lodash.forin/README.md index 62a0bae8f..1e414c4de 100644 --- a/lodash.forin/README.md +++ b/lodash.forin/README.md @@ -1,4 +1,4 @@ -# lodash.forin v4.0.1 +# lodash.forin v4.0.2 The [lodash](https://lodash.com/) method `_.forIn` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var forIn = require('lodash.forin'); ``` -See the [documentation](https://lodash.com/docs#forIn) or [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash.forin) for more details. +See the [documentation](https://lodash.com/docs#forIn) or [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash.forin) for more details. diff --git a/lodash.forin/index.js b/lodash.forin/index.js index 629ef1a24..66466c298 100644 --- a/lodash.forin/index.js +++ b/lodash.forin/index.js @@ -1,5 +1,5 @@ /** - * lodash 4.0.1 (Custom Build) + * lodash 4.0.2 (Custom Build) * Build: `lodash modularize exports="npm" -o ./` * Copyright 2012-2016 The Dojo Foundation * Based on Underscore.js 1.8.3 diff --git a/lodash.forin/package.json b/lodash.forin/package.json index e99a0b2d2..af0dc3637 100644 --- a/lodash.forin/package.json +++ b/lodash.forin/package.json @@ -1,6 +1,6 @@ { "name": "lodash.forin", - "version": "4.0.1", + "version": "4.0.2", "description": "The lodash method `_.forIn` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", @@ -9,13 +9,13 @@ "author": "John-David Dalton (http://allyoucanleet.com/)", "contributors": [ "John-David Dalton (http://allyoucanleet.com/)", - "Blaine Bublitz (https://github.com/phated)", + "Blaine Bublitz (https://github.com/phated)", "Mathias Bynens (https://mathiasbynens.be/)" ], "repository": "lodash/lodash", "scripts": { "test": "echo \"See https://travis-ci.org/lodash/lodash-cli for testing details.\"" }, "dependencies": { - "lodash._basefor": "^3.0.0", + "lodash._basefor": "~3.0.0", "lodash.keysin": "^4.0.0" } } diff --git a/lodash.forown/README.md b/lodash.forown/README.md index 0c9c25fe9..e1d550bc9 100644 --- a/lodash.forown/README.md +++ b/lodash.forown/README.md @@ -1,4 +1,4 @@ -# lodash.forown v4.0.1 +# lodash.forown v4.0.2 The [lodash](https://lodash.com/) method `_.forOwn` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var forOwn = require('lodash.forown'); ``` -See the [documentation](https://lodash.com/docs#forOwn) or [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash.forown) for more details. +See the [documentation](https://lodash.com/docs#forOwn) or [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash.forown) for more details. diff --git a/lodash.forown/index.js b/lodash.forown/index.js index 062ff0380..0941aa63f 100644 --- a/lodash.forown/index.js +++ b/lodash.forown/index.js @@ -1,5 +1,5 @@ /** - * lodash 4.0.1 (Custom Build) + * lodash 4.0.2 (Custom Build) * Build: `lodash modularize exports="npm" -o ./` * Copyright 2012-2016 The Dojo Foundation * Based on Underscore.js 1.8.3 diff --git a/lodash.forown/package.json b/lodash.forown/package.json index 6a2ba5cad..472de0a60 100644 --- a/lodash.forown/package.json +++ b/lodash.forown/package.json @@ -1,6 +1,6 @@ { "name": "lodash.forown", - "version": "4.0.1", + "version": "4.0.2", "description": "The lodash method `_.forOwn` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", @@ -9,13 +9,13 @@ "author": "John-David Dalton (http://allyoucanleet.com/)", "contributors": [ "John-David Dalton (http://allyoucanleet.com/)", - "Blaine Bublitz (https://github.com/phated)", + "Blaine Bublitz (https://github.com/phated)", "Mathias Bynens (https://mathiasbynens.be/)" ], "repository": "lodash/lodash", "scripts": { "test": "echo \"See https://travis-ci.org/lodash/lodash-cli for testing details.\"" }, "dependencies": { - "lodash._basefor": "^3.0.0", + "lodash._basefor": "~3.0.0", "lodash.keys": "^4.0.0" } } diff --git a/lodash.get/README.md b/lodash.get/README.md index e21402f83..8290a0dc9 100644 --- a/lodash.get/README.md +++ b/lodash.get/README.md @@ -1,4 +1,4 @@ -# lodash.get v4.0.1 +# lodash.get v4.0.2 The [lodash](https://lodash.com/) method `_.get` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var get = require('lodash.get'); ``` -See the [documentation](https://lodash.com/docs#get) or [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash.get) for more details. +See the [documentation](https://lodash.com/docs#get) or [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash.get) for more details. diff --git a/lodash.get/index.js b/lodash.get/index.js index ed37e73b1..6209dedf8 100644 --- a/lodash.get/index.js +++ b/lodash.get/index.js @@ -1,5 +1,5 @@ /** - * lodash 4.0.1 (Custom Build) + * lodash 4.0.2 (Custom Build) * Build: `lodash modularize exports="npm" -o ./` * Copyright 2012-2016 The Dojo Foundation * Based on Underscore.js 1.8.3 @@ -21,8 +21,51 @@ var reIsDeepProp = /\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/, /** Used to match backslashes in property paths. */ var reEscapeChar = /\\(\\)?/g; +/** Used to determine if values are of the language type `Object`. */ +var objectTypes = { + 'function': true, + 'object': true +}; + +/** Detect free variable `exports`. */ +var freeExports = (objectTypes[typeof exports] && exports && !exports.nodeType) ? exports : null; + +/** Detect free variable `module`. */ +var freeModule = (objectTypes[typeof module] && module && !module.nodeType) ? module : null; + +/** Detect free variable `global` from Node.js. */ +var freeGlobal = checkGlobal(freeExports && freeModule && typeof global == 'object' && global); + +/** Detect free variable `self`. */ +var freeSelf = checkGlobal(objectTypes[typeof self] && self); + +/** Detect free variable `window`. */ +var freeWindow = checkGlobal(objectTypes[typeof window] && window); + +/** Detect `this` as the global object. */ +var thisGlobal = checkGlobal(objectTypes[typeof this] && this); + +/** + * Used as a reference to the global object. + * + * The `this` value is used if it's the global object to avoid Greasemonkey's + * restricted `window` object, otherwise the `window` object is used. + */ +var root = freeGlobal || ((freeWindow !== (thisGlobal && thisGlobal.window)) && freeWindow) || freeSelf || thisGlobal || Function('return this')(); + +/** + * Checks if `value` is a global object. + * + * @private + * @param {*} value The value to check. + * @returns {null|Object} Returns `value` if it's a global object, else `null`. + */ +function checkGlobal(value) { + return (value && value.Object === Object) ? value : null; +} + /** Used for built-in method references. */ -var objectProto = global.Object.prototype; +var objectProto = Object.prototype; /** * Used to resolve the [`toStringTag`](http://ecma-international.org/ecma-262/6.0/#sec-object.prototype.tostring) @@ -31,7 +74,7 @@ var objectProto = global.Object.prototype; var objectToString = objectProto.toString; /** Built-in value references. */ -var Symbol = global.Symbol; +var Symbol = root.Symbol; /** Used to convert symbols to primitives and strings. */ var symbolProto = Symbol ? Symbol.prototype : undefined, diff --git a/lodash.get/package.json b/lodash.get/package.json index cdf5bbe3e..a830b26b8 100644 --- a/lodash.get/package.json +++ b/lodash.get/package.json @@ -1,11 +1,11 @@ { "name": "lodash.get", - "version": "4.0.1", + "version": "4.0.2", "description": "The lodash method `_.get` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", "license": "MIT", - "keywords": "lodash, lodash-modularized, stdlib, util, get", + "keywords": "lodash-modularized, get", "author": "John-David Dalton (http://allyoucanleet.com/)", "contributors": [ "John-David Dalton (http://allyoucanleet.com/)", diff --git a/lodash.groupby/README.md b/lodash.groupby/README.md index b375317b0..54e0136ae 100644 --- a/lodash.groupby/README.md +++ b/lodash.groupby/README.md @@ -1,4 +1,4 @@ -# lodash.groupby v4.0.1 +# lodash.groupby v4.0.2 The [lodash](https://lodash.com/) method `_.groupBy` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var groupBy = require('lodash.groupby'); ``` -See the [documentation](https://lodash.com/docs#groupBy) or [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash.groupby) for more details. +See the [documentation](https://lodash.com/docs#groupBy) or [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash.groupby) for more details. diff --git a/lodash.groupby/index.js b/lodash.groupby/index.js index 1ee12cc3c..cfb2e512b 100644 --- a/lodash.groupby/index.js +++ b/lodash.groupby/index.js @@ -1,5 +1,5 @@ /** - * lodash 4.0.1 (Custom Build) + * lodash 4.0.2 (Custom Build) * Build: `lodash modularize exports="npm" -o ./` * Copyright 2012-2016 The Dojo Foundation * Based on Underscore.js 1.8.3 @@ -31,6 +31,27 @@ var reIsDeepProp = /\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/, /** Used to match backslashes in property paths. */ var reEscapeChar = /\\(\\)?/g; +/** + * A specialized version of `baseAggregator` for arrays. + * + * @private + * @param {Array} array The array to iterate over. + * @param {Function} setter The function to set `accumulator` values. + * @param {Function} iteratee The iteratee to transform keys. + * @param {Object} accumulator The initial aggregated object. + * @returns {Function} Returns `accumulator`. + */ +function arrayAggregator(array, setter, iteratee, accumulator) { + var index = -1, + length = array.length; + + while (++index < length) { + var value = array[index]; + setter(accumulator, value, iteratee(value), array); + } + return accumulator; +} + /** Used for built-in method references. */ var objectProto = global.Object.prototype; @@ -50,6 +71,24 @@ var Symbol = global.Symbol; var symbolProto = Symbol ? Symbol.prototype : undefined, symbolToString = Symbol ? symbolProto.toString : undefined; +/** + * Aggregates elements of `collection` on `accumulator` with keys transformed + * by `iteratee` and values set by `setter`. + * + * @private + * @param {Array|Object} collection The collection to iterate over. + * @param {Function} setter The function to set `accumulator` values. + * @param {Function} iteratee The iteratee to transform keys. + * @param {Object} accumulator The initial aggregated object. + * @returns {Function} Returns `accumulator`. + */ +function baseAggregator(collection, setter, iteratee, accumulator) { + baseEach(collection, function(value, key, collection) { + setter(accumulator, value, iteratee(value), collection); + }); + return accumulator; +} + /** * The base implementation of `_.get` without support for default values. * @@ -178,29 +217,16 @@ function baseToPath(value) { * Creates a function like `_.groupBy`. * * @private - * @param {Function} setter The function to set keys and values of the accumulator object. - * @param {Function} [initializer] The function to initialize the accumulator object. + * @param {Function} setter The function to set accumulator values. + * @param {Function} [initializer] The accumulator object initializer. * @returns {Function} Returns the new aggregator function. */ function createAggregator(setter, initializer) { return function(collection, iteratee) { - var result = initializer ? initializer() : {}; - iteratee = baseIteratee(iteratee); + var func = isArray(collection) ? arrayAggregator : baseAggregator, + accumulator = initializer ? initializer() : {}; - if (isArray(collection)) { - var index = -1, - length = collection.length; - - while (++index < length) { - var value = collection[index]; - setter(result, value, iteratee(value), collection); - } - } else { - baseEach(collection, function(value, key, collection) { - setter(result, value, iteratee(value), collection); - }); - } - return result; + return func(collection, setter, baseIteratee(iteratee), accumulator); }; } @@ -343,8 +369,6 @@ var isArray = Array.isArray; * // => false */ function isObject(value) { - // Avoid a V8 JIT bug in Chrome 19-20. - // See https://code.google.com/p/v8/issues/detail?id=2291 for more details. var type = typeof value; return !!value && (type == 'object' || type == 'function'); } diff --git a/lodash.groupby/package.json b/lodash.groupby/package.json index 71cde78eb..d8a441943 100644 --- a/lodash.groupby/package.json +++ b/lodash.groupby/package.json @@ -1,11 +1,11 @@ { "name": "lodash.groupby", - "version": "4.0.1", + "version": "4.0.2", "description": "The lodash method `_.groupBy` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", "license": "MIT", - "keywords": "lodash, lodash-modularized, stdlib, util, groupby", + "keywords": "lodash-modularized, groupby", "author": "John-David Dalton (http://allyoucanleet.com/)", "contributors": [ "John-David Dalton (http://allyoucanleet.com/)", diff --git a/lodash.has/README.md b/lodash.has/README.md index f5c9cfd54..80a37dca2 100644 --- a/lodash.has/README.md +++ b/lodash.has/README.md @@ -1,4 +1,4 @@ -# lodash.has v4.0.1 +# lodash.has v4.0.2 The [lodash](https://lodash.com/) method `_.has` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var has = require('lodash.has'); ``` -See the [documentation](https://lodash.com/docs#has) or [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash.has) for more details. +See the [documentation](https://lodash.com/docs#has) or [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash.has) for more details. diff --git a/lodash.has/index.js b/lodash.has/index.js index 55faf2074..83b6c8de9 100644 --- a/lodash.has/index.js +++ b/lodash.has/index.js @@ -1,5 +1,5 @@ /** - * lodash 4.0.1 (Custom Build) + * lodash 4.0.2 (Custom Build) * Build: `lodash modularize exports="npm" -o ./` * Copyright 2012-2016 The Dojo Foundation * Based on Underscore.js 1.8.3 @@ -141,8 +141,11 @@ function hasPath(object, path, hasFunc) { result = hasFunc(object, path); } } - return result || (isLength(object && object.length) && isIndex(path, object.length) && - (isArray(object) || isString(object) || isArguments(object))); + var length = object ? object.length : undefined; + return result || ( + !!length && isLength(length) && isIndex(path, length) && + (isArray(object) || isString(object) || isArguments(object)) + ); } /** @@ -388,8 +391,6 @@ function isLength(value) { * // => false */ function isObject(value) { - // Avoid a V8 JIT bug in Chrome 19-20. - // See https://code.google.com/p/v8/issues/detail?id=2291 for more details. var type = typeof value; return !!value && (type == 'object' || type == 'function'); } diff --git a/lodash.has/package.json b/lodash.has/package.json index 15faab3bd..156df15a6 100644 --- a/lodash.has/package.json +++ b/lodash.has/package.json @@ -1,11 +1,11 @@ { "name": "lodash.has", - "version": "4.0.1", + "version": "4.0.2", "description": "The lodash method `_.has` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", "license": "MIT", - "keywords": "lodash, lodash-modularized, stdlib, util, has", + "keywords": "lodash-modularized, has", "author": "John-David Dalton (http://allyoucanleet.com/)", "contributors": [ "John-David Dalton (http://allyoucanleet.com/)", diff --git a/lodash.hasin/README.md b/lodash.hasin/README.md index dab5d1ace..8a636893a 100644 --- a/lodash.hasin/README.md +++ b/lodash.hasin/README.md @@ -1,4 +1,4 @@ -# lodash.hasin v4.0.1 +# lodash.hasin v4.0.2 The [lodash](https://lodash.com/) method `_.hasIn` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var hasIn = require('lodash.hasin'); ``` -See the [documentation](https://lodash.com/docs#hasIn) or [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash.hasin) for more details. +See the [documentation](https://lodash.com/docs#hasIn) or [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash.hasin) for more details. diff --git a/lodash.hasin/index.js b/lodash.hasin/index.js index 7e428c81b..8e76f62d8 100644 --- a/lodash.hasin/index.js +++ b/lodash.hasin/index.js @@ -1,5 +1,5 @@ /** - * lodash 4.0.1 (Custom Build) + * lodash 4.0.2 (Custom Build) * Build: `lodash modularize exports="npm" -o ./` * Copyright 2012-2016 The Dojo Foundation * Based on Underscore.js 1.8.3 @@ -136,8 +136,11 @@ function hasPath(object, path, hasFunc) { result = hasFunc(object, path); } } - return result || (isLength(object && object.length) && isIndex(path, object.length) && - (isArray(object) || isString(object) || isArguments(object))); + var length = object ? object.length : undefined; + return result || ( + !!length && isLength(length) && isIndex(path, length) && + (isArray(object) || isString(object) || isArguments(object)) + ); } /** @@ -383,8 +386,6 @@ function isLength(value) { * // => false */ function isObject(value) { - // Avoid a V8 JIT bug in Chrome 19-20. - // See https://code.google.com/p/v8/issues/detail?id=2291 for more details. var type = typeof value; return !!value && (type == 'object' || type == 'function'); } diff --git a/lodash.hasin/package.json b/lodash.hasin/package.json index 5f96e7001..aedd880b9 100644 --- a/lodash.hasin/package.json +++ b/lodash.hasin/package.json @@ -1,11 +1,11 @@ { "name": "lodash.hasin", - "version": "4.0.1", + "version": "4.0.2", "description": "The lodash method `_.hasIn` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", "license": "MIT", - "keywords": "lodash, lodash-modularized, stdlib, util, hasin", + "keywords": "lodash-modularized, hasin", "author": "John-David Dalton (http://allyoucanleet.com/)", "contributors": [ "John-David Dalton (http://allyoucanleet.com/)", diff --git a/lodash.indexof/LICENSE b/lodash.indexof/LICENSE index b054ca5a3..e0c69d560 100644 --- a/lodash.indexof/LICENSE +++ b/lodash.indexof/LICENSE @@ -1,7 +1,17 @@ -Copyright 2012-2016 The Dojo Foundation -Based on Underscore.js, copyright 2009-2016 Jeremy Ashkenas, +Copyright jQuery Foundation and other contributors + +Based on Underscore.js, copyright Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors +This software consists of voluntary contributions made by many +individuals. For exact contribution history, see the revision history +available at https://github.com/lodash/lodash + +The following license applies to all parts of this software except as +documented below: + +==== + Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including @@ -20,3 +30,18 @@ NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + +==== + +Copyright and related rights for sample code are waived via CC0. Sample +code is defined as all source code displayed within the prose of the +documentation. + +CC0: http://creativecommons.org/publicdomain/zero/1.0/ + +==== + +Files located in the node_modules and vendor directories are externally +maintained libraries used by this software which have their own +licenses; we recommend you read them, as their terms may differ from the +terms above. diff --git a/lodash.indexof/README.md b/lodash.indexof/README.md index 39753d187..09320557e 100644 --- a/lodash.indexof/README.md +++ b/lodash.indexof/README.md @@ -1,4 +1,4 @@ -# lodash.indexof v4.0.1 +# lodash.indexof v4.0.2 The [lodash](https://lodash.com/) method `_.indexOf` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var indexOf = require('lodash.indexof'); ``` -See the [documentation](https://lodash.com/docs#indexOf) or [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash.indexof) for more details. +See the [documentation](https://lodash.com/docs#indexOf) or [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash.indexof) for more details. diff --git a/lodash.indexof/index.js b/lodash.indexof/index.js index 9bf833960..80e8119e8 100644 --- a/lodash.indexof/index.js +++ b/lodash.indexof/index.js @@ -1,10 +1,10 @@ /** - * lodash 4.0.1 (Custom Build) + * lodash 4.0.2 (Custom Build) * Build: `lodash modularize exports="npm" -o ./` - * Copyright 2012-2016 The Dojo Foundation + * Copyright jQuery Foundation and other contributors + * Released under MIT license * Based on Underscore.js 1.8.3 - * Copyright 2009-2016 Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors - * Available under MIT license + * Copyright Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors */ /** Used as references for various `Number` constants. */ @@ -14,7 +14,8 @@ var INFINITY = 1 / 0, /** `Object#toString` result references. */ var funcTag = '[object Function]', - genTag = '[object GeneratorFunction]'; + genTag = '[object GeneratorFunction]', + symbolTag = '[object Symbol]'; /** Used to match leading and trailing whitespace. */ var reTrim = /^\s+|\s+$/g; @@ -81,7 +82,8 @@ function indexOfNaN(array, fromIndex, fromRight) { var objectProto = Object.prototype; /** - * Used to resolve the [`toStringTag`](http://ecma-international.org/ecma-262/6.0/#sec-object.prototype.tostring) + * Used to resolve the + * [`toStringTag`](http://ecma-international.org/ecma-262/6.0/#sec-object.prototype.tostring) * of values. */ var objectToString = objectProto.toString; @@ -92,11 +94,12 @@ var nativeMax = Math.max; /** * Gets the index at which the first occurrence of `value` is found in `array` * using [`SameValueZero`](http://ecma-international.org/ecma-262/6.0/#sec-samevaluezero) - * for equality comparisons. If `fromIndex` is negative, it's used as the offset - * from the end of `array`. + * for equality comparisons. If `fromIndex` is negative, it's used as the + * offset from the end of `array`. * * @static * @memberOf _ + * @since 0.1.0 * @category Array * @param {Array} array The array to search. * @param {*} value The value to search for. @@ -128,9 +131,11 @@ function indexOf(array, value, fromIndex) { * * @static * @memberOf _ + * @since 0.1.0 * @category Lang * @param {*} value The value to check. - * @returns {boolean} Returns `true` if `value` is correctly classified, else `false`. + * @returns {boolean} Returns `true` if `value` is correctly classified, + * else `false`. * @example * * _.isFunction(_); @@ -148,11 +153,13 @@ function isFunction(value) { } /** - * Checks if `value` is the [language type](https://es5.github.io/#x8) of `Object`. - * (e.g. arrays, functions, objects, regexes, `new Number(0)`, and `new String('')`) + * Checks if `value` is the + * [language type](http://www.ecma-international.org/ecma-262/6.0/#sec-ecmascript-language-types) + * of `Object`. (e.g. arrays, functions, objects, regexes, `new Number(0)`, and `new String('')`) * * @static * @memberOf _ + * @since 0.1.0 * @category Lang * @param {*} value The value to check. * @returns {boolean} Returns `true` if `value` is an object, else `false`. @@ -176,12 +183,65 @@ function isObject(value) { } /** - * Converts `value` to an integer. - * - * **Note:** This function is loosely based on [`ToInteger`](http://www.ecma-international.org/ecma-262/6.0/#sec-tointeger). + * Checks if `value` is object-like. A value is object-like if it's not `null` + * and has a `typeof` result of "object". * * @static * @memberOf _ + * @since 4.0.0 + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is object-like, else `false`. + * @example + * + * _.isObjectLike({}); + * // => true + * + * _.isObjectLike([1, 2, 3]); + * // => true + * + * _.isObjectLike(_.noop); + * // => false + * + * _.isObjectLike(null); + * // => false + */ +function isObjectLike(value) { + return !!value && typeof value == 'object'; +} + +/** + * Checks if `value` is classified as a `Symbol` primitive or object. + * + * @static + * @memberOf _ + * @since 4.0.0 + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is correctly classified, + * else `false`. + * @example + * + * _.isSymbol(Symbol.iterator); + * // => true + * + * _.isSymbol('abc'); + * // => false + */ +function isSymbol(value) { + return typeof value == 'symbol' || + (isObjectLike(value) && objectToString.call(value) == symbolTag); +} + +/** + * Converts `value` to an integer. + * + * **Note:** This function is loosely based on + * [`ToInteger`](http://www.ecma-international.org/ecma-262/6.0/#sec-tointeger). + * + * @static + * @memberOf _ + * @since 4.0.0 * @category Lang * @param {*} value The value to convert. * @returns {number} Returns the converted integer. @@ -217,6 +277,7 @@ function toInteger(value) { * * @static * @memberOf _ + * @since 4.0.0 * @category Lang * @param {*} value The value to process. * @returns {number} Returns the number. @@ -235,6 +296,12 @@ function toInteger(value) { * // => 3 */ function toNumber(value) { + if (typeof value == 'number') { + return value; + } + if (isSymbol(value)) { + return NAN; + } if (isObject(value)) { var other = isFunction(value.valueOf) ? value.valueOf() : value; value = isObject(other) ? (other + '') : other; diff --git a/lodash.indexof/package.json b/lodash.indexof/package.json index c1b10e908..51087789a 100644 --- a/lodash.indexof/package.json +++ b/lodash.indexof/package.json @@ -1,6 +1,6 @@ { "name": "lodash.indexof", - "version": "4.0.1", + "version": "4.0.2", "description": "The lodash method `_.indexOf` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", @@ -9,7 +9,7 @@ "author": "John-David Dalton (http://allyoucanleet.com/)", "contributors": [ "John-David Dalton (http://allyoucanleet.com/)", - "Blaine Bublitz (https://github.com/phated)", + "Blaine Bublitz (https://github.com/phated)", "Mathias Bynens (https://mathiasbynens.be/)" ], "repository": "lodash/lodash", diff --git a/lodash.initial/LICENSE b/lodash.initial/LICENSE index b054ca5a3..bcbe13d67 100644 --- a/lodash.initial/LICENSE +++ b/lodash.initial/LICENSE @@ -1,22 +1,23 @@ +The MIT License (MIT) + Copyright 2012-2016 The Dojo Foundation Based on Underscore.js, copyright 2009-2016 Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors -Permission is hereby granted, free of charge, to any person obtaining -a copy of this software and associated documentation files (the -"Software"), to deal in the Software without restriction, including -without limitation the rights to use, copy, modify, merge, publish, -distribute, sublicense, and/or sell copies of the Software, and to -permit persons to whom the Software is furnished to do so, subject to -the following conditions: +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: -The above copyright notice and this permission notice shall be -included in all copies or substantial portions of the Software. +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, -EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND -NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE -LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION -OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION -WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. diff --git a/lodash.initial/README.md b/lodash.initial/README.md index 305720bd1..3259c9de0 100644 --- a/lodash.initial/README.md +++ b/lodash.initial/README.md @@ -1,4 +1,4 @@ -# lodash.initial v4.0.1 +# lodash.initial v4.0.2 The [lodash](https://lodash.com/) method `_.initial` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var initial = require('lodash.initial'); ``` -See the [documentation](https://lodash.com/docs#initial) or [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash.initial) for more details. +See the [documentation](https://lodash.com/docs#initial) or [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash.initial) for more details. diff --git a/lodash.initial/index.js b/lodash.initial/index.js index c8f663cf4..9cce0a544 100644 --- a/lodash.initial/index.js +++ b/lodash.initial/index.js @@ -1,5 +1,5 @@ /** - * lodash 4.0.1 (Custom Build) + * lodash 4.0.2 (Custom Build) * Build: `lodash modularize exports="npm" -o ./` * Copyright 2012-2016 The Dojo Foundation * Based on Underscore.js 1.8.3 diff --git a/lodash.initial/package.json b/lodash.initial/package.json index 438e49b8b..1412b466c 100644 --- a/lodash.initial/package.json +++ b/lodash.initial/package.json @@ -1,6 +1,6 @@ { "name": "lodash.initial", - "version": "4.0.1", + "version": "4.0.2", "description": "The lodash method `_.initial` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", @@ -9,12 +9,12 @@ "author": "John-David Dalton (http://allyoucanleet.com/)", "contributors": [ "John-David Dalton (http://allyoucanleet.com/)", - "Blaine Bublitz (https://github.com/phated)", + "Blaine Bublitz (https://github.com/phated)", "Mathias Bynens (https://mathiasbynens.be/)" ], "repository": "lodash/lodash", "scripts": { "test": "echo \"See https://travis-ci.org/lodash/lodash-cli for testing details.\"" }, "dependencies": { - "lodash._baseslice": "^4.0.0" + "lodash._baseslice": "~4.0.0" } } diff --git a/lodash.intersection/README.md b/lodash.intersection/README.md index 6861f71f5..ab5092819 100644 --- a/lodash.intersection/README.md +++ b/lodash.intersection/README.md @@ -1,4 +1,4 @@ -# lodash.intersection v4.0.1 +# lodash.intersection v4.0.2 The [lodash](https://lodash.com/) method `_.intersection` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var intersection = require('lodash.intersection'); ``` -See the [documentation](https://lodash.com/docs#intersection) or [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash.intersection) for more details. +See the [documentation](https://lodash.com/docs#intersection) or [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash.intersection) for more details. diff --git a/lodash.intersection/index.js b/lodash.intersection/index.js index a1ea82059..ea2662e57 100644 --- a/lodash.intersection/index.js +++ b/lodash.intersection/index.js @@ -1,5 +1,5 @@ /** - * lodash 4.0.1 (Custom Build) + * lodash 4.0.2 (Custom Build) * Build: `lodash modularize exports="npm" -o ./` * Copyright 2012-2016 The Dojo Foundation * Based on Underscore.js 1.8.3 @@ -34,7 +34,7 @@ function baseUnary(func) { } /** Used for built-in method references. */ -var objectProto = global.Object.prototype; +var objectProto = Object.prototype; /** * Used to resolve the [`toStringTag`](http://ecma-international.org/ecma-262/6.0/#sec-object.prototype.tostring) @@ -133,8 +133,8 @@ function toArrayLikeObject(value) { } /** - * Creates an array of unique values that are included in all of the provided - * arrays using [`SameValueZero`](http://ecma-international.org/ecma-262/6.0/#sec-samevaluezero) + * Creates an array of unique values that are included in all given arrays + * using [`SameValueZero`](http://ecma-international.org/ecma-262/6.0/#sec-samevaluezero) * for equality comparisons. * * @static diff --git a/lodash.intersection/package.json b/lodash.intersection/package.json index 183d5a68f..7d078e8bb 100644 --- a/lodash.intersection/package.json +++ b/lodash.intersection/package.json @@ -1,11 +1,11 @@ { "name": "lodash.intersection", - "version": "4.0.1", + "version": "4.0.2", "description": "The lodash method `_.intersection` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", "license": "MIT", - "keywords": "lodash, lodash-modularized, stdlib, util, intersection", + "keywords": "lodash-modularized, intersection", "author": "John-David Dalton (http://allyoucanleet.com/)", "contributors": [ "John-David Dalton (http://allyoucanleet.com/)", diff --git a/lodash.intersectionby/README.md b/lodash.intersectionby/README.md index 88fc10738..12c39315b 100644 --- a/lodash.intersectionby/README.md +++ b/lodash.intersectionby/README.md @@ -1,4 +1,4 @@ -# lodash.intersectionby v4.0.1 +# lodash.intersectionby v4.0.2 The [lodash](https://lodash.com/) method `_.intersectionBy` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var intersectionBy = require('lodash.intersectionby'); ``` -See the [documentation](https://lodash.com/docs#intersectionBy) or [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash.intersectionby) for more details. +See the [documentation](https://lodash.com/docs#intersectionBy) or [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash.intersectionby) for more details. diff --git a/lodash.intersectionby/index.js b/lodash.intersectionby/index.js index 82598da1a..78f638110 100644 --- a/lodash.intersectionby/index.js +++ b/lodash.intersectionby/index.js @@ -1,5 +1,5 @@ /** - * lodash 4.0.0 (Custom Build) + * lodash 4.0.2 (Custom Build) * Build: `lodash modularize exports="npm" -o ./` * Copyright 2012-2016 The Dojo Foundation * Based on Underscore.js 1.8.3 @@ -62,11 +62,11 @@ var objectProto = global.Object.prototype; var objectToString = objectProto.toString; /** Built-in value references. */ -var _Symbol = global.Symbol; +var Symbol = global.Symbol; /** Used to convert symbols to primitives and strings. */ -var symbolProto = _Symbol ? _Symbol.prototype : undefined, - symbolToString = _Symbol ? symbolProto.toString : undefined; +var symbolProto = Symbol ? Symbol.prototype : undefined, + symbolToString = Symbol ? symbolProto.toString : undefined; /** * The base implementation of `_.get` without support for default values. @@ -541,8 +541,6 @@ function isLength(value) { * // => false */ function isObject(value) { - // Avoid a V8 JIT bug in Chrome 19-20. - // See https://code.google.com/p/v8/issues/detail?id=2291 for more details. var type = typeof value; return !!value && (type == 'object' || type == 'function'); } @@ -624,7 +622,7 @@ function toString(value) { return ''; } if (isSymbol(value)) { - return _Symbol ? symbolToString.call(value) : ''; + return Symbol ? symbolToString.call(value) : ''; } var result = (value + ''); return (result == '0' && (1 / value) == -INFINITY) ? '-0' : result; diff --git a/lodash.intersectionby/package.json b/lodash.intersectionby/package.json index f83893e4f..ca320e685 100644 --- a/lodash.intersectionby/package.json +++ b/lodash.intersectionby/package.json @@ -1,6 +1,6 @@ { "name": "lodash.intersectionby", - "version": "4.0.1", + "version": "4.0.2", "description": "The lodash method `_.intersectionBy` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", diff --git a/lodash.intersectionwith/README.md b/lodash.intersectionwith/README.md index 00bfe204d..c954be3c5 100644 --- a/lodash.intersectionwith/README.md +++ b/lodash.intersectionwith/README.md @@ -1,4 +1,4 @@ -# lodash.intersectionwith v4.0.1 +# lodash.intersectionwith v4.0.2 The [lodash](https://lodash.com/) method `_.intersectionWith` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var intersectionWith = require('lodash.intersectionwith'); ``` -See the [documentation](https://lodash.com/docs#intersectionWith) or [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash.intersectionwith) for more details. +See the [documentation](https://lodash.com/docs#intersectionWith) or [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash.intersectionwith) for more details. diff --git a/lodash.intersectionwith/index.js b/lodash.intersectionwith/index.js index 427097c08..9e5f2cf7e 100644 --- a/lodash.intersectionwith/index.js +++ b/lodash.intersectionwith/index.js @@ -1,5 +1,5 @@ /** - * lodash 4.0.1 (Custom Build) + * lodash 4.0.2 (Custom Build) * Build: `lodash modularize exports="npm" -o ./` * Copyright 2012-2016 The Dojo Foundation * Based on Underscore.js 1.8.3 @@ -34,7 +34,7 @@ function baseUnary(func) { } /** Used for built-in method references. */ -var objectProto = global.Object.prototype; +var objectProto = Object.prototype; /** * Used to resolve the [`toStringTag`](http://ecma-international.org/ecma-262/6.0/#sec-object.prototype.tostring) diff --git a/lodash.intersectionwith/package.json b/lodash.intersectionwith/package.json index ddd8ae15f..64d0069d3 100644 --- a/lodash.intersectionwith/package.json +++ b/lodash.intersectionwith/package.json @@ -1,11 +1,11 @@ { "name": "lodash.intersectionwith", - "version": "4.0.1", + "version": "4.0.2", "description": "The lodash method `_.intersectionWith` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", "license": "MIT", - "keywords": "lodash, lodash-modularized, stdlib, util, intersectionwith", + "keywords": "lodash-modularized, intersectionwith", "author": "John-David Dalton (http://allyoucanleet.com/)", "contributors": [ "John-David Dalton (http://allyoucanleet.com/)", diff --git a/lodash.invoke/README.md b/lodash.invoke/README.md index 2d4cf5e69..d2f251a73 100644 --- a/lodash.invoke/README.md +++ b/lodash.invoke/README.md @@ -1,4 +1,4 @@ -# lodash.invoke v4.0.1 +# lodash.invoke v4.0.2 The [lodash](https://lodash.com/) method `_.invoke` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var invoke = require('lodash.invoke'); ``` -See the [documentation](https://lodash.com/docs#invoke) or [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash.invoke) for more details. +See the [documentation](https://lodash.com/docs#invoke) or [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash.invoke) for more details. diff --git a/lodash.invoke/index.js b/lodash.invoke/index.js index f86083e25..a308bb18f 100644 --- a/lodash.invoke/index.js +++ b/lodash.invoke/index.js @@ -1,5 +1,5 @@ /** - * lodash 4.0.1 (Custom Build) + * lodash 4.0.2 (Custom Build) * Build: `lodash modularize exports="npm" -o ./` * Copyright 2012-2016 The Dojo Foundation * Based on Underscore.js 1.8.3 @@ -24,6 +24,38 @@ var reIsDeepProp = /\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/, /** Used to match backslashes in property paths. */ var reEscapeChar = /\\(\\)?/g; +/** Used to determine if values are of the language type `Object`. */ +var objectTypes = { + 'function': true, + 'object': true +}; + +/** Detect free variable `exports`. */ +var freeExports = (objectTypes[typeof exports] && exports && !exports.nodeType) ? exports : null; + +/** Detect free variable `module`. */ +var freeModule = (objectTypes[typeof module] && module && !module.nodeType) ? module : null; + +/** Detect free variable `global` from Node.js. */ +var freeGlobal = checkGlobal(freeExports && freeModule && typeof global == 'object' && global); + +/** Detect free variable `self`. */ +var freeSelf = checkGlobal(objectTypes[typeof self] && self); + +/** Detect free variable `window`. */ +var freeWindow = checkGlobal(objectTypes[typeof window] && window); + +/** Detect `this` as the global object. */ +var thisGlobal = checkGlobal(objectTypes[typeof this] && this); + +/** + * Used as a reference to the global object. + * + * The `this` value is used if it's the global object to avoid Greasemonkey's + * restricted `window` object, otherwise the `window` object is used. + */ +var root = freeGlobal || ((freeWindow !== (thisGlobal && thisGlobal.window)) && freeWindow) || freeSelf || thisGlobal || Function('return this')(); + /** * A faster alternative to `Function#apply`, this function invokes `func` * with the `this` binding of `thisArg` and the arguments of `args`. @@ -31,11 +63,11 @@ var reEscapeChar = /\\(\\)?/g; * @private * @param {Function} func The function to invoke. * @param {*} thisArg The `this` binding of `func`. - * @param {...*} [args] The arguments to invoke `func` with. + * @param {...*} args The arguments to invoke `func` with. * @returns {*} Returns the result of `func`. */ function apply(func, thisArg, args) { - var length = args ? args.length : 0; + var length = args.length; switch (length) { case 0: return func.call(thisArg); case 1: return func.call(thisArg, args[0]); @@ -45,8 +77,19 @@ function apply(func, thisArg, args) { return func.apply(thisArg, args); } +/** + * Checks if `value` is a global object. + * + * @private + * @param {*} value The value to check. + * @returns {null|Object} Returns `value` if it's a global object, else `null`. + */ +function checkGlobal(value) { + return (value && value.Object === Object) ? value : null; +} + /** Used for built-in method references. */ -var objectProto = global.Object.prototype; +var objectProto = Object.prototype; /** * Used to resolve the [`toStringTag`](http://ecma-international.org/ecma-262/6.0/#sec-object.prototype.tostring) @@ -55,7 +98,7 @@ var objectProto = global.Object.prototype; var objectToString = objectProto.toString; /** Built-in value references. */ -var Symbol = global.Symbol; +var Symbol = root.Symbol; /** Used to convert symbols to primitives and strings. */ var symbolProto = Symbol ? Symbol.prototype : undefined, diff --git a/lodash.invoke/package.json b/lodash.invoke/package.json index 3fcd0aa01..dbe97fac2 100644 --- a/lodash.invoke/package.json +++ b/lodash.invoke/package.json @@ -1,11 +1,11 @@ { "name": "lodash.invoke", - "version": "4.0.1", + "version": "4.0.2", "description": "The lodash method `_.invoke` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", "license": "MIT", - "keywords": "lodash, lodash-modularized, stdlib, util, invoke", + "keywords": "lodash-modularized, invoke", "author": "John-David Dalton (http://allyoucanleet.com/)", "contributors": [ "John-David Dalton (http://allyoucanleet.com/)", diff --git a/lodash.invokemap/README.md b/lodash.invokemap/README.md index daf2bc5a5..4c6246136 100644 --- a/lodash.invokemap/README.md +++ b/lodash.invokemap/README.md @@ -1,4 +1,4 @@ -# lodash.invokemap v4.0.1 +# lodash.invokemap v4.0.2 The [lodash](https://lodash.com/) method `_.invokeMap` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var invokeMap = require('lodash.invokemap'); ``` -See the [documentation](https://lodash.com/docs#invokeMap) or [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash.invokemap) for more details. +See the [documentation](https://lodash.com/docs#invokeMap) or [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash.invokemap) for more details. diff --git a/lodash.invokemap/index.js b/lodash.invokemap/index.js index 5ef415a49..0c43820c5 100644 --- a/lodash.invokemap/index.js +++ b/lodash.invokemap/index.js @@ -1,5 +1,5 @@ /** - * lodash 4.0.1 (Custom Build) + * lodash 4.0.2 (Custom Build) * Build: `lodash modularize exports="npm" -o ./` * Copyright 2012-2016 The Dojo Foundation * Based on Underscore.js 1.8.3 @@ -28,6 +28,38 @@ var reIsDeepProp = /\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/, /** Used to match backslashes in property paths. */ var reEscapeChar = /\\(\\)?/g; +/** Used to determine if values are of the language type `Object`. */ +var objectTypes = { + 'function': true, + 'object': true +}; + +/** Detect free variable `exports`. */ +var freeExports = (objectTypes[typeof exports] && exports && !exports.nodeType) ? exports : null; + +/** Detect free variable `module`. */ +var freeModule = (objectTypes[typeof module] && module && !module.nodeType) ? module : null; + +/** Detect free variable `global` from Node.js. */ +var freeGlobal = checkGlobal(freeExports && freeModule && typeof global == 'object' && global); + +/** Detect free variable `self`. */ +var freeSelf = checkGlobal(objectTypes[typeof self] && self); + +/** Detect free variable `window`. */ +var freeWindow = checkGlobal(objectTypes[typeof window] && window); + +/** Detect `this` as the global object. */ +var thisGlobal = checkGlobal(objectTypes[typeof this] && this); + +/** + * Used as a reference to the global object. + * + * The `this` value is used if it's the global object to avoid Greasemonkey's + * restricted `window` object, otherwise the `window` object is used. + */ +var root = freeGlobal || ((freeWindow !== (thisGlobal && thisGlobal.window)) && freeWindow) || freeSelf || thisGlobal || Function('return this')(); + /** * A faster alternative to `Function#apply`, this function invokes `func` * with the `this` binding of `thisArg` and the arguments of `args`. @@ -35,11 +67,11 @@ var reEscapeChar = /\\(\\)?/g; * @private * @param {Function} func The function to invoke. * @param {*} thisArg The `this` binding of `func`. - * @param {...*} [args] The arguments to invoke `func` with. + * @param {...*} args The arguments to invoke `func` with. * @returns {*} Returns the result of `func`. */ function apply(func, thisArg, args) { - var length = args ? args.length : 0; + var length = args.length; switch (length) { case 0: return func.call(thisArg); case 1: return func.call(thisArg, args[0]); @@ -49,8 +81,19 @@ function apply(func, thisArg, args) { return func.apply(thisArg, args); } +/** + * Checks if `value` is a global object. + * + * @private + * @param {*} value The value to check. + * @returns {null|Object} Returns `value` if it's a global object, else `null`. + */ +function checkGlobal(value) { + return (value && value.Object === Object) ? value : null; +} + /** Used for built-in method references. */ -var objectProto = global.Object.prototype; +var objectProto = Object.prototype; /** * Used to resolve the [`toStringTag`](http://ecma-international.org/ecma-262/6.0/#sec-object.prototype.tostring) @@ -59,7 +102,7 @@ var objectProto = global.Object.prototype; var objectToString = objectProto.toString; /** Built-in value references. */ -var Symbol = global.Symbol; +var Symbol = root.Symbol; /** Used to convert symbols to primitives and strings. */ var symbolProto = Symbol ? Symbol.prototype : undefined, diff --git a/lodash.invokemap/package.json b/lodash.invokemap/package.json index e8b16e754..40b2085f8 100644 --- a/lodash.invokemap/package.json +++ b/lodash.invokemap/package.json @@ -1,11 +1,11 @@ { "name": "lodash.invokemap", - "version": "4.0.1", + "version": "4.0.2", "description": "The lodash method `_.invokeMap` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", "license": "MIT", - "keywords": "lodash, lodash-modularized, stdlib, util, invokemap", + "keywords": "lodash-modularized, invokemap", "author": "John-David Dalton (http://allyoucanleet.com/)", "contributors": [ "John-David Dalton (http://allyoucanleet.com/)", diff --git a/lodash.isarraylike/LICENSE b/lodash.isarraylike/LICENSE index b054ca5a3..bcbe13d67 100644 --- a/lodash.isarraylike/LICENSE +++ b/lodash.isarraylike/LICENSE @@ -1,22 +1,23 @@ +The MIT License (MIT) + Copyright 2012-2016 The Dojo Foundation Based on Underscore.js, copyright 2009-2016 Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors -Permission is hereby granted, free of charge, to any person obtaining -a copy of this software and associated documentation files (the -"Software"), to deal in the Software without restriction, including -without limitation the rights to use, copy, modify, merge, publish, -distribute, sublicense, and/or sell copies of the Software, and to -permit persons to whom the Software is furnished to do so, subject to -the following conditions: +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: -The above copyright notice and this permission notice shall be -included in all copies or substantial portions of the Software. +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, -EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND -NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE -LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION -OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION -WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. diff --git a/lodash.isarraylike/README.md b/lodash.isarraylike/README.md index dbd1bed78..104944987 100644 --- a/lodash.isarraylike/README.md +++ b/lodash.isarraylike/README.md @@ -1,4 +1,4 @@ -# lodash.isarraylike v4.0.1 +# lodash.isarraylike v4.0.2 The [lodash](https://lodash.com/) method `_.isArrayLike` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var isArrayLike = require('lodash.isarraylike'); ``` -See the [documentation](https://lodash.com/docs#isArrayLike) or [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash.isarraylike) for more details. +See the [documentation](https://lodash.com/docs#isArrayLike) or [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash.isarraylike) for more details. diff --git a/lodash.isarraylike/index.js b/lodash.isarraylike/index.js index c46e390b1..156512fbe 100644 --- a/lodash.isarraylike/index.js +++ b/lodash.isarraylike/index.js @@ -1,5 +1,5 @@ /** - * lodash 4.0.1 (Custom Build) + * lodash 4.0.2 (Custom Build) * Build: `lodash modularize exports="npm" -o ./` * Copyright 2012-2016 The Dojo Foundation * Based on Underscore.js 1.8.3 @@ -55,7 +55,6 @@ var getLength = baseProperty('length'); * * @static * @memberOf _ - * @type Function * @category Lang * @param {*} value The value to check. * @returns {boolean} Returns `true` if `value` is array-like, else `false`. @@ -127,7 +126,8 @@ function isFunction(value) { * // => false */ function isLength(value) { - return typeof value == 'number' && value > -1 && value % 1 == 0 && value <= MAX_SAFE_INTEGER; + return typeof value == 'number' && + value > -1 && value % 1 == 0 && value <= MAX_SAFE_INTEGER; } /** diff --git a/lodash.isarraylike/package.json b/lodash.isarraylike/package.json index e051bc478..119f7c3ce 100644 --- a/lodash.isarraylike/package.json +++ b/lodash.isarraylike/package.json @@ -1,6 +1,6 @@ { "name": "lodash.isarraylike", - "version": "4.0.1", + "version": "4.0.2", "description": "The lodash method `_.isArrayLike` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", diff --git a/lodash.isarraylikeobject/LICENSE b/lodash.isarraylikeobject/LICENSE index b054ca5a3..bcbe13d67 100644 --- a/lodash.isarraylikeobject/LICENSE +++ b/lodash.isarraylikeobject/LICENSE @@ -1,22 +1,23 @@ +The MIT License (MIT) + Copyright 2012-2016 The Dojo Foundation Based on Underscore.js, copyright 2009-2016 Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors -Permission is hereby granted, free of charge, to any person obtaining -a copy of this software and associated documentation files (the -"Software"), to deal in the Software without restriction, including -without limitation the rights to use, copy, modify, merge, publish, -distribute, sublicense, and/or sell copies of the Software, and to -permit persons to whom the Software is furnished to do so, subject to -the following conditions: +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: -The above copyright notice and this permission notice shall be -included in all copies or substantial portions of the Software. +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, -EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND -NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE -LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION -OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION -WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. diff --git a/lodash.isarraylikeobject/README.md b/lodash.isarraylikeobject/README.md index 20b5f96e5..4b5938958 100644 --- a/lodash.isarraylikeobject/README.md +++ b/lodash.isarraylikeobject/README.md @@ -1,4 +1,4 @@ -# lodash.isarraylikeobject v4.0.1 +# lodash.isarraylikeobject v4.0.2 The [lodash](https://lodash.com/) method `_.isArrayLikeObject` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var isArrayLikeObject = require('lodash.isarraylikeobject'); ``` -See the [documentation](https://lodash.com/docs#isArrayLikeObject) or [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash.isarraylikeobject) for more details. +See the [documentation](https://lodash.com/docs#isArrayLikeObject) or [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash.isarraylikeobject) for more details. diff --git a/lodash.isarraylikeobject/index.js b/lodash.isarraylikeobject/index.js index 66e854f5b..0b8fcf09e 100644 --- a/lodash.isarraylikeobject/index.js +++ b/lodash.isarraylikeobject/index.js @@ -1,5 +1,5 @@ /** - * lodash 4.0.1 (Custom Build) + * lodash 4.0.2 (Custom Build) * Build: `lodash modularize exports="npm" -o ./` * Copyright 2012-2016 The Dojo Foundation * Based on Underscore.js 1.8.3 @@ -55,7 +55,6 @@ var getLength = baseProperty('length'); * * @static * @memberOf _ - * @type Function * @category Lang * @param {*} value The value to check. * @returns {boolean} Returns `true` if `value` is array-like, else `false`. @@ -84,7 +83,6 @@ function isArrayLike(value) { * * @static * @memberOf _ - * @type Function * @category Lang * @param {*} value The value to check. * @returns {boolean} Returns `true` if `value` is an array-like object, else `false`. @@ -155,7 +153,8 @@ function isFunction(value) { * // => false */ function isLength(value) { - return typeof value == 'number' && value > -1 && value % 1 == 0 && value <= MAX_SAFE_INTEGER; + return typeof value == 'number' && + value > -1 && value % 1 == 0 && value <= MAX_SAFE_INTEGER; } /** diff --git a/lodash.isarraylikeobject/package.json b/lodash.isarraylikeobject/package.json index 3f24356b4..fb2447b16 100644 --- a/lodash.isarraylikeobject/package.json +++ b/lodash.isarraylikeobject/package.json @@ -1,6 +1,6 @@ { "name": "lodash.isarraylikeobject", - "version": "4.0.1", + "version": "4.0.2", "description": "The lodash method `_.isArrayLikeObject` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", diff --git a/lodash.isinteger/LICENSE b/lodash.isinteger/LICENSE index b054ca5a3..e0c69d560 100644 --- a/lodash.isinteger/LICENSE +++ b/lodash.isinteger/LICENSE @@ -1,7 +1,17 @@ -Copyright 2012-2016 The Dojo Foundation -Based on Underscore.js, copyright 2009-2016 Jeremy Ashkenas, +Copyright jQuery Foundation and other contributors + +Based on Underscore.js, copyright Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors +This software consists of voluntary contributions made by many +individuals. For exact contribution history, see the revision history +available at https://github.com/lodash/lodash + +The following license applies to all parts of this software except as +documented below: + +==== + Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including @@ -20,3 +30,18 @@ NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + +==== + +Copyright and related rights for sample code are waived via CC0. Sample +code is defined as all source code displayed within the prose of the +documentation. + +CC0: http://creativecommons.org/publicdomain/zero/1.0/ + +==== + +Files located in the node_modules and vendor directories are externally +maintained libraries used by this software which have their own +licenses; we recommend you read them, as their terms may differ from the +terms above. diff --git a/lodash.isinteger/README.md b/lodash.isinteger/README.md index ca01cc468..f1f7703af 100644 --- a/lodash.isinteger/README.md +++ b/lodash.isinteger/README.md @@ -1,4 +1,4 @@ -# lodash.isinteger v4.0.1 +# lodash.isinteger v4.0.2 The [lodash](https://lodash.com/) method `_.isInteger` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var isInteger = require('lodash.isinteger'); ``` -See the [documentation](https://lodash.com/docs#isInteger) or [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash.isinteger) for more details. +See the [documentation](https://lodash.com/docs#isInteger) or [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash.isinteger) for more details. diff --git a/lodash.isinteger/index.js b/lodash.isinteger/index.js index e649da4de..dcd674e31 100644 --- a/lodash.isinteger/index.js +++ b/lodash.isinteger/index.js @@ -1,10 +1,10 @@ /** - * lodash 4.0.1 (Custom Build) + * lodash 4.0.2 (Custom Build) * Build: `lodash modularize exports="npm" -o ./` - * Copyright 2012-2016 The Dojo Foundation + * Copyright jQuery Foundation and other contributors + * Released under MIT license * Based on Underscore.js 1.8.3 - * Copyright 2009-2016 Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors - * Available under MIT license + * Copyright Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors */ /** Used as references for various `Number` constants. */ @@ -14,7 +14,8 @@ var INFINITY = 1 / 0, /** `Object#toString` result references. */ var funcTag = '[object Function]', - genTag = '[object GeneratorFunction]'; + genTag = '[object GeneratorFunction]', + symbolTag = '[object Symbol]'; /** Used to match leading and trailing whitespace. */ var reTrim = /^\s+|\s+$/g; @@ -35,7 +36,8 @@ var freeParseInt = parseInt; var objectProto = Object.prototype; /** - * Used to resolve the [`toStringTag`](http://ecma-international.org/ecma-262/6.0/#sec-object.prototype.tostring) + * Used to resolve the + * [`toStringTag`](http://ecma-international.org/ecma-262/6.0/#sec-object.prototype.tostring) * of values. */ var objectToString = objectProto.toString; @@ -45,9 +47,11 @@ var objectToString = objectProto.toString; * * @static * @memberOf _ + * @since 0.1.0 * @category Lang * @param {*} value The value to check. - * @returns {boolean} Returns `true` if `value` is correctly classified, else `false`. + * @returns {boolean} Returns `true` if `value` is correctly classified, + * else `false`. * @example * * _.isFunction(_); @@ -67,10 +71,12 @@ function isFunction(value) { /** * Checks if `value` is an integer. * - * **Note:** This method is based on [`Number.isInteger`](https://mdn.io/Number/isInteger). + * **Note:** This method is based on + * [`Number.isInteger`](https://mdn.io/Number/isInteger). * * @static * @memberOf _ + * @since 4.0.0 * @category Lang * @param {*} value The value to check. * @returns {boolean} Returns `true` if `value` is an integer, else `false`. @@ -93,11 +99,13 @@ function isInteger(value) { } /** - * Checks if `value` is the [language type](https://es5.github.io/#x8) of `Object`. - * (e.g. arrays, functions, objects, regexes, `new Number(0)`, and `new String('')`) + * Checks if `value` is the + * [language type](http://www.ecma-international.org/ecma-262/6.0/#sec-ecmascript-language-types) + * of `Object`. (e.g. arrays, functions, objects, regexes, `new Number(0)`, and `new String('')`) * * @static * @memberOf _ + * @since 0.1.0 * @category Lang * @param {*} value The value to check. * @returns {boolean} Returns `true` if `value` is an object, else `false`. @@ -121,12 +129,65 @@ function isObject(value) { } /** - * Converts `value` to an integer. - * - * **Note:** This function is loosely based on [`ToInteger`](http://www.ecma-international.org/ecma-262/6.0/#sec-tointeger). + * Checks if `value` is object-like. A value is object-like if it's not `null` + * and has a `typeof` result of "object". * * @static * @memberOf _ + * @since 4.0.0 + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is object-like, else `false`. + * @example + * + * _.isObjectLike({}); + * // => true + * + * _.isObjectLike([1, 2, 3]); + * // => true + * + * _.isObjectLike(_.noop); + * // => false + * + * _.isObjectLike(null); + * // => false + */ +function isObjectLike(value) { + return !!value && typeof value == 'object'; +} + +/** + * Checks if `value` is classified as a `Symbol` primitive or object. + * + * @static + * @memberOf _ + * @since 4.0.0 + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is correctly classified, + * else `false`. + * @example + * + * _.isSymbol(Symbol.iterator); + * // => true + * + * _.isSymbol('abc'); + * // => false + */ +function isSymbol(value) { + return typeof value == 'symbol' || + (isObjectLike(value) && objectToString.call(value) == symbolTag); +} + +/** + * Converts `value` to an integer. + * + * **Note:** This function is loosely based on + * [`ToInteger`](http://www.ecma-international.org/ecma-262/6.0/#sec-tointeger). + * + * @static + * @memberOf _ + * @since 4.0.0 * @category Lang * @param {*} value The value to convert. * @returns {number} Returns the converted integer. @@ -162,6 +223,7 @@ function toInteger(value) { * * @static * @memberOf _ + * @since 4.0.0 * @category Lang * @param {*} value The value to process. * @returns {number} Returns the number. @@ -180,6 +242,12 @@ function toInteger(value) { * // => 3 */ function toNumber(value) { + if (typeof value == 'number') { + return value; + } + if (isSymbol(value)) { + return NAN; + } if (isObject(value)) { var other = isFunction(value.valueOf) ? value.valueOf() : value; value = isObject(other) ? (other + '') : other; diff --git a/lodash.isinteger/package.json b/lodash.isinteger/package.json index ca5ba7e8b..828f7e38f 100644 --- a/lodash.isinteger/package.json +++ b/lodash.isinteger/package.json @@ -1,6 +1,6 @@ { "name": "lodash.isinteger", - "version": "4.0.1", + "version": "4.0.2", "description": "The lodash method `_.isInteger` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", @@ -9,7 +9,7 @@ "author": "John-David Dalton (http://allyoucanleet.com/)", "contributors": [ "John-David Dalton (http://allyoucanleet.com/)", - "Blaine Bublitz (https://github.com/phated)", + "Blaine Bublitz (https://github.com/phated)", "Mathias Bynens (https://mathiasbynens.be/)" ], "repository": "lodash/lodash", diff --git a/lodash.isplainobject/LICENSE b/lodash.isplainobject/LICENSE index b054ca5a3..bcbe13d67 100644 --- a/lodash.isplainobject/LICENSE +++ b/lodash.isplainobject/LICENSE @@ -1,22 +1,23 @@ +The MIT License (MIT) + Copyright 2012-2016 The Dojo Foundation Based on Underscore.js, copyright 2009-2016 Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors -Permission is hereby granted, free of charge, to any person obtaining -a copy of this software and associated documentation files (the -"Software"), to deal in the Software without restriction, including -without limitation the rights to use, copy, modify, merge, publish, -distribute, sublicense, and/or sell copies of the Software, and to -permit persons to whom the Software is furnished to do so, subject to -the following conditions: +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: -The above copyright notice and this permission notice shall be -included in all copies or substantial portions of the Software. +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, -EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND -NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE -LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION -OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION -WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. diff --git a/lodash.isplainobject/README.md b/lodash.isplainobject/README.md index 42c15736b..b23d81afa 100644 --- a/lodash.isplainobject/README.md +++ b/lodash.isplainobject/README.md @@ -1,4 +1,4 @@ -# lodash.isplainobject v4.0.1 +# lodash.isplainobject v4.0.2 The [lodash](https://lodash.com/) method `_.isPlainObject` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var isPlainObject = require('lodash.isplainobject'); ``` -See the [documentation](https://lodash.com/docs#isPlainObject) or [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash.isplainobject) for more details. +See the [documentation](https://lodash.com/docs#isPlainObject) or [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash.isplainobject) for more details. diff --git a/lodash.isplainobject/index.js b/lodash.isplainobject/index.js index 3f57cc333..d7361d492 100644 --- a/lodash.isplainobject/index.js +++ b/lodash.isplainobject/index.js @@ -1,5 +1,5 @@ /** - * lodash 4.0.1 (Custom Build) + * lodash 4.0.2 (Custom Build) * Build: `lodash modularize exports="npm" -o ./` * Copyright 2012-2016 The Dojo Foundation * Based on Underscore.js 1.8.3 @@ -102,7 +102,8 @@ function isObjectLike(value) { * // => true */ function isPlainObject(value) { - if (!isObjectLike(value) || objectToString.call(value) != objectTag || isHostObject(value)) { + if (!isObjectLike(value) || + objectToString.call(value) != objectTag || isHostObject(value)) { return false; } var proto = objectProto; diff --git a/lodash.isplainobject/package.json b/lodash.isplainobject/package.json index 1a93994b7..093101f3c 100644 --- a/lodash.isplainobject/package.json +++ b/lodash.isplainobject/package.json @@ -1,6 +1,6 @@ { "name": "lodash.isplainobject", - "version": "4.0.1", + "version": "4.0.2", "description": "The lodash method `_.isPlainObject` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", diff --git a/lodash.issafeinteger/LICENSE b/lodash.issafeinteger/LICENSE index b054ca5a3..e0c69d560 100644 --- a/lodash.issafeinteger/LICENSE +++ b/lodash.issafeinteger/LICENSE @@ -1,7 +1,17 @@ -Copyright 2012-2016 The Dojo Foundation -Based on Underscore.js, copyright 2009-2016 Jeremy Ashkenas, +Copyright jQuery Foundation and other contributors + +Based on Underscore.js, copyright Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors +This software consists of voluntary contributions made by many +individuals. For exact contribution history, see the revision history +available at https://github.com/lodash/lodash + +The following license applies to all parts of this software except as +documented below: + +==== + Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including @@ -20,3 +30,18 @@ NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + +==== + +Copyright and related rights for sample code are waived via CC0. Sample +code is defined as all source code displayed within the prose of the +documentation. + +CC0: http://creativecommons.org/publicdomain/zero/1.0/ + +==== + +Files located in the node_modules and vendor directories are externally +maintained libraries used by this software which have their own +licenses; we recommend you read them, as their terms may differ from the +terms above. diff --git a/lodash.issafeinteger/README.md b/lodash.issafeinteger/README.md index 381df46a6..479092d6d 100644 --- a/lodash.issafeinteger/README.md +++ b/lodash.issafeinteger/README.md @@ -1,4 +1,4 @@ -# lodash.issafeinteger v4.0.1 +# lodash.issafeinteger v4.0.2 The [lodash](https://lodash.com/) method `_.isSafeInteger` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var isSafeInteger = require('lodash.issafeinteger'); ``` -See the [documentation](https://lodash.com/docs#isSafeInteger) or [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash.issafeinteger) for more details. +See the [documentation](https://lodash.com/docs#isSafeInteger) or [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash.issafeinteger) for more details. diff --git a/lodash.issafeinteger/index.js b/lodash.issafeinteger/index.js index e6a88d252..2628c0d32 100644 --- a/lodash.issafeinteger/index.js +++ b/lodash.issafeinteger/index.js @@ -1,10 +1,10 @@ /** - * lodash 4.0.1 (Custom Build) + * lodash 4.0.2 (Custom Build) * Build: `lodash modularize exports="npm" -o ./` - * Copyright 2012-2016 The Dojo Foundation + * Copyright jQuery Foundation and other contributors + * Released under MIT license * Based on Underscore.js 1.8.3 - * Copyright 2009-2016 Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors - * Available under MIT license + * Copyright Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors */ /** Used as references for various `Number` constants. */ @@ -15,7 +15,8 @@ var INFINITY = 1 / 0, /** `Object#toString` result references. */ var funcTag = '[object Function]', - genTag = '[object GeneratorFunction]'; + genTag = '[object GeneratorFunction]', + symbolTag = '[object Symbol]'; /** Used to match leading and trailing whitespace. */ var reTrim = /^\s+|\s+$/g; @@ -36,7 +37,8 @@ var freeParseInt = parseInt; var objectProto = Object.prototype; /** - * Used to resolve the [`toStringTag`](http://ecma-international.org/ecma-262/6.0/#sec-object.prototype.tostring) + * Used to resolve the + * [`toStringTag`](http://ecma-international.org/ecma-262/6.0/#sec-object.prototype.tostring) * of values. */ var objectToString = objectProto.toString; @@ -46,9 +48,11 @@ var objectToString = objectProto.toString; * * @static * @memberOf _ + * @since 0.1.0 * @category Lang * @param {*} value The value to check. - * @returns {boolean} Returns `true` if `value` is correctly classified, else `false`. + * @returns {boolean} Returns `true` if `value` is correctly classified, + * else `false`. * @example * * _.isFunction(_); @@ -68,10 +72,12 @@ function isFunction(value) { /** * Checks if `value` is an integer. * - * **Note:** This method is based on [`Number.isInteger`](https://mdn.io/Number/isInteger). + * **Note:** This method is based on + * [`Number.isInteger`](https://mdn.io/Number/isInteger). * * @static * @memberOf _ + * @since 4.0.0 * @category Lang * @param {*} value The value to check. * @returns {boolean} Returns `true` if `value` is an integer, else `false`. @@ -94,11 +100,13 @@ function isInteger(value) { } /** - * Checks if `value` is the [language type](https://es5.github.io/#x8) of `Object`. - * (e.g. arrays, functions, objects, regexes, `new Number(0)`, and `new String('')`) + * Checks if `value` is the + * [language type](http://www.ecma-international.org/ecma-262/6.0/#sec-ecmascript-language-types) + * of `Object`. (e.g. arrays, functions, objects, regexes, `new Number(0)`, and `new String('')`) * * @static * @memberOf _ + * @since 0.1.0 * @category Lang * @param {*} value The value to check. * @returns {boolean} Returns `true` if `value` is an object, else `false`. @@ -122,16 +130,47 @@ function isObject(value) { } /** - * Checks if `value` is a safe integer. An integer is safe if it's an IEEE-754 - * double precision number which isn't the result of a rounded unsafe integer. - * - * **Note:** This method is based on [`Number.isSafeInteger`](https://mdn.io/Number/isSafeInteger). + * Checks if `value` is object-like. A value is object-like if it's not `null` + * and has a `typeof` result of "object". * * @static * @memberOf _ + * @since 4.0.0 * @category Lang * @param {*} value The value to check. - * @returns {boolean} Returns `true` if `value` is a safe integer, else `false`. + * @returns {boolean} Returns `true` if `value` is object-like, else `false`. + * @example + * + * _.isObjectLike({}); + * // => true + * + * _.isObjectLike([1, 2, 3]); + * // => true + * + * _.isObjectLike(_.noop); + * // => false + * + * _.isObjectLike(null); + * // => false + */ +function isObjectLike(value) { + return !!value && typeof value == 'object'; +} + +/** + * Checks if `value` is a safe integer. An integer is safe if it's an IEEE-754 + * double precision number which isn't the result of a rounded unsafe integer. + * + * **Note:** This method is based on + * [`Number.isSafeInteger`](https://mdn.io/Number/isSafeInteger). + * + * @static + * @memberOf _ + * @since 4.0.0 + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is a safe integer, + * else `false`. * @example * * _.isSafeInteger(3); @@ -151,12 +190,37 @@ function isSafeInteger(value) { } /** - * Converts `value` to an integer. - * - * **Note:** This function is loosely based on [`ToInteger`](http://www.ecma-international.org/ecma-262/6.0/#sec-tointeger). + * Checks if `value` is classified as a `Symbol` primitive or object. * * @static * @memberOf _ + * @since 4.0.0 + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is correctly classified, + * else `false`. + * @example + * + * _.isSymbol(Symbol.iterator); + * // => true + * + * _.isSymbol('abc'); + * // => false + */ +function isSymbol(value) { + return typeof value == 'symbol' || + (isObjectLike(value) && objectToString.call(value) == symbolTag); +} + +/** + * Converts `value` to an integer. + * + * **Note:** This function is loosely based on + * [`ToInteger`](http://www.ecma-international.org/ecma-262/6.0/#sec-tointeger). + * + * @static + * @memberOf _ + * @since 4.0.0 * @category Lang * @param {*} value The value to convert. * @returns {number} Returns the converted integer. @@ -192,6 +256,7 @@ function toInteger(value) { * * @static * @memberOf _ + * @since 4.0.0 * @category Lang * @param {*} value The value to process. * @returns {number} Returns the number. @@ -210,6 +275,12 @@ function toInteger(value) { * // => 3 */ function toNumber(value) { + if (typeof value == 'number') { + return value; + } + if (isSymbol(value)) { + return NAN; + } if (isObject(value)) { var other = isFunction(value.valueOf) ? value.valueOf() : value; value = isObject(other) ? (other + '') : other; diff --git a/lodash.issafeinteger/package.json b/lodash.issafeinteger/package.json index a5a377bff..73dbf5009 100644 --- a/lodash.issafeinteger/package.json +++ b/lodash.issafeinteger/package.json @@ -1,6 +1,6 @@ { "name": "lodash.issafeinteger", - "version": "4.0.1", + "version": "4.0.2", "description": "The lodash method `_.isSafeInteger` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", @@ -9,7 +9,7 @@ "author": "John-David Dalton (http://allyoucanleet.com/)", "contributors": [ "John-David Dalton (http://allyoucanleet.com/)", - "Blaine Bublitz (https://github.com/phated)", + "Blaine Bublitz (https://github.com/phated)", "Mathias Bynens (https://mathiasbynens.be/)" ], "repository": "lodash/lodash", diff --git a/lodash.iteratee/README.md b/lodash.iteratee/README.md index 9e1ff6ba9..133155690 100644 --- a/lodash.iteratee/README.md +++ b/lodash.iteratee/README.md @@ -1,4 +1,4 @@ -# lodash.iteratee v4.0.1 +# lodash.iteratee v4.0.2 The [lodash](https://lodash.com/) method `_.iteratee` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var iteratee = require('lodash.iteratee'); ``` -See the [documentation](https://lodash.com/docs#iteratee) or [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash.iteratee) for more details. +See the [documentation](https://lodash.com/docs#iteratee) or [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash.iteratee) for more details. diff --git a/lodash.iteratee/index.js b/lodash.iteratee/index.js index b10eeb301..a24f75d02 100644 --- a/lodash.iteratee/index.js +++ b/lodash.iteratee/index.js @@ -1,5 +1,5 @@ /** - * lodash 4.0.0 (Custom Build) + * lodash 4.0.2 (Custom Build) * Build: `lodash modularize exports="npm" -o ./` * Copyright 2012-2016 The Dojo Foundation * Based on Underscore.js 1.8.3 @@ -118,14 +118,14 @@ function addSetEntry(set, value) { * @param {Array} array The array to iterate over. * @param {Function} iteratee The function invoked per iteration. * @param {*} [accumulator] The initial value. - * @param {boolean} [initFromArray] Specify using the first element of `array` as the initial value. + * @param {boolean} [initAccum] Specify using the first element of `array` as the initial value. * @returns {*} Returns the accumulated value. */ -function arrayReduce(array, iteratee, accumulator, initFromArray) { +function arrayReduce(array, iteratee, accumulator, initAccum) { var index = -1, length = array.length; - if (initFromArray && length) { + if (initAccum && length) { accumulator = array[++index]; } while (++index < length) { @@ -209,7 +209,7 @@ var reIsNative = RegExp('^' + ); /** Built-in value references. */ -var _Symbol = global.Symbol, +var Symbol = global.Symbol, Uint8Array = global.Uint8Array, getOwnPropertySymbols = Object.getOwnPropertySymbols; @@ -222,9 +222,9 @@ var mapCtorString = Map ? funcToString.call(Map) : '', setCtorString = Set ? funcToString.call(Set) : ''; /** Used to convert symbols to primitives and strings. */ -var symbolProto = _Symbol ? _Symbol.prototype : undefined, - symbolValueOf = _Symbol ? symbolProto.valueOf : undefined, - symbolToString = _Symbol ? symbolProto.toString : undefined; +var symbolProto = Symbol ? Symbol.prototype : undefined, + symbolValueOf = Symbol ? symbolProto.valueOf : undefined, + symbolToString = Symbol ? symbolProto.toString : undefined; /** * Assigns `value` to `key` of `object` if the existing value is not equivalent @@ -540,7 +540,7 @@ function cloneSet(set) { * @returns {Object} Returns the cloned symbol object. */ function cloneSymbol(symbol) { - return _Symbol ? Object(symbolValueOf.call(symbol)) : {}; + return Symbol ? Object(symbolValueOf.call(symbol)) : {}; } /** @@ -1036,7 +1036,7 @@ function toString(value) { return ''; } if (isSymbol(value)) { - return _Symbol ? symbolToString.call(value) : ''; + return Symbol ? symbolToString.call(value) : ''; } var result = (value + ''); return (result == '0' && (1 / value) == -INFINITY) ? '-0' : result; diff --git a/lodash.iteratee/package.json b/lodash.iteratee/package.json index 9559f727d..2db823b55 100644 --- a/lodash.iteratee/package.json +++ b/lodash.iteratee/package.json @@ -1,6 +1,6 @@ { "name": "lodash.iteratee", - "version": "4.0.1", + "version": "4.0.2", "description": "The lodash method `_.iteratee` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", diff --git a/lodash.keyby/README.md b/lodash.keyby/README.md index a44ecb6eb..e3fcd236f 100644 --- a/lodash.keyby/README.md +++ b/lodash.keyby/README.md @@ -1,4 +1,4 @@ -# lodash.keyby v4.0.1 +# lodash.keyby v4.0.2 The [lodash](https://lodash.com/) method `_.keyBy` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var keyBy = require('lodash.keyby'); ``` -See the [documentation](https://lodash.com/docs#keyBy) or [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash.keyby) for more details. +See the [documentation](https://lodash.com/docs#keyBy) or [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash.keyby) for more details. diff --git a/lodash.keyby/index.js b/lodash.keyby/index.js index 934fa8f91..4ad20071a 100644 --- a/lodash.keyby/index.js +++ b/lodash.keyby/index.js @@ -1,5 +1,5 @@ /** - * lodash 4.0.1 (Custom Build) + * lodash 4.0.2 (Custom Build) * Build: `lodash modularize exports="npm" -o ./` * Copyright 2012-2016 The Dojo Foundation * Based on Underscore.js 1.8.3 @@ -31,6 +31,27 @@ var reIsDeepProp = /\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/, /** Used to match backslashes in property paths. */ var reEscapeChar = /\\(\\)?/g; +/** + * A specialized version of `baseAggregator` for arrays. + * + * @private + * @param {Array} array The array to iterate over. + * @param {Function} setter The function to set `accumulator` values. + * @param {Function} iteratee The iteratee to transform keys. + * @param {Object} accumulator The initial aggregated object. + * @returns {Function} Returns `accumulator`. + */ +function arrayAggregator(array, setter, iteratee, accumulator) { + var index = -1, + length = array.length; + + while (++index < length) { + var value = array[index]; + setter(accumulator, value, iteratee(value), array); + } + return accumulator; +} + /** Used for built-in method references. */ var objectProto = global.Object.prototype; @@ -47,6 +68,24 @@ var Symbol = global.Symbol; var symbolProto = Symbol ? Symbol.prototype : undefined, symbolToString = Symbol ? symbolProto.toString : undefined; +/** + * Aggregates elements of `collection` on `accumulator` with keys transformed + * by `iteratee` and values set by `setter`. + * + * @private + * @param {Array|Object} collection The collection to iterate over. + * @param {Function} setter The function to set `accumulator` values. + * @param {Function} iteratee The iteratee to transform keys. + * @param {Object} accumulator The initial aggregated object. + * @returns {Function} Returns `accumulator`. + */ +function baseAggregator(collection, setter, iteratee, accumulator) { + baseEach(collection, function(value, key, collection) { + setter(accumulator, value, iteratee(value), collection); + }); + return accumulator; +} + /** * The base implementation of `_.get` without support for default values. * @@ -175,29 +214,16 @@ function baseToPath(value) { * Creates a function like `_.groupBy`. * * @private - * @param {Function} setter The function to set keys and values of the accumulator object. - * @param {Function} [initializer] The function to initialize the accumulator object. + * @param {Function} setter The function to set accumulator values. + * @param {Function} [initializer] The accumulator object initializer. * @returns {Function} Returns the new aggregator function. */ function createAggregator(setter, initializer) { return function(collection, iteratee) { - var result = initializer ? initializer() : {}; - iteratee = baseIteratee(iteratee); + var func = isArray(collection) ? arrayAggregator : baseAggregator, + accumulator = initializer ? initializer() : {}; - if (isArray(collection)) { - var index = -1, - length = collection.length; - - while (++index < length) { - var value = collection[index]; - setter(result, value, iteratee(value), collection); - } - } else { - baseEach(collection, function(value, key, collection) { - setter(result, value, iteratee(value), collection); - }); - } - return result; + return func(collection, setter, baseIteratee(iteratee), accumulator); }; } @@ -276,17 +302,17 @@ function stringToPath(string) { * @returns {Object} Returns the composed aggregate object. * @example * - * var keyData = [ + * var array = [ * { 'dir': 'left', 'code': 97 }, * { 'dir': 'right', 'code': 100 } * ]; * - * _.keyBy(keyData, function(o) { + * _.keyBy(array, function(o) { * return String.fromCharCode(o.code); * }); * // => { 'a': { 'dir': 'left', 'code': 97 }, 'd': { 'dir': 'right', 'code': 100 } } * - * _.keyBy(keyData, 'dir'); + * _.keyBy(array, 'dir'); * // => { 'left': { 'dir': 'left', 'code': 97 }, 'right': { 'dir': 'right', 'code': 100 } } */ var keyBy = createAggregator(function(result, value, key) { @@ -342,8 +368,6 @@ var isArray = Array.isArray; * // => false */ function isObject(value) { - // Avoid a V8 JIT bug in Chrome 19-20. - // See https://code.google.com/p/v8/issues/detail?id=2291 for more details. var type = typeof value; return !!value && (type == 'object' || type == 'function'); } diff --git a/lodash.keyby/package.json b/lodash.keyby/package.json index 2c238311f..bb837abef 100644 --- a/lodash.keyby/package.json +++ b/lodash.keyby/package.json @@ -1,11 +1,11 @@ { "name": "lodash.keyby", - "version": "4.0.1", + "version": "4.0.2", "description": "The lodash method `_.keyBy` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", "license": "MIT", - "keywords": "lodash, lodash-modularized, stdlib, util, keyby", + "keywords": "lodash-modularized, keyby", "author": "John-David Dalton (http://allyoucanleet.com/)", "contributors": [ "John-David Dalton (http://allyoucanleet.com/)", diff --git a/lodash.keys/README.md b/lodash.keys/README.md index caea85f91..2b36548a6 100644 --- a/lodash.keys/README.md +++ b/lodash.keys/README.md @@ -1,4 +1,4 @@ -# lodash.keys v4.0.1 +# lodash.keys v4.0.2 The [lodash](https://lodash.com/) method `_.keys` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var keys = require('lodash.keys'); ``` -See the [documentation](https://lodash.com/docs#keys) or [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash.keys) for more details. +See the [documentation](https://lodash.com/docs#keys) or [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash.keys) for more details. diff --git a/lodash.keys/index.js b/lodash.keys/index.js index 0007fce69..00ef3c302 100644 --- a/lodash.keys/index.js +++ b/lodash.keys/index.js @@ -1,5 +1,5 @@ /** - * lodash 4.0.1 (Custom Build) + * lodash 4.0.2 (Custom Build) * Build: `lodash modularize exports="npm" -o ./` * Copyright 2012-2016 The Dojo Foundation * Based on Underscore.js 1.8.3 @@ -53,7 +53,7 @@ function isIndex(value, length) { } /** Used for built-in method references. */ -var objectProto = global.Object.prototype; +var objectProto = Object.prototype; /** Used to check objects for own properties. */ var hasOwnProperty = objectProto.hasOwnProperty; diff --git a/lodash.keys/package.json b/lodash.keys/package.json index 75d6364a5..d4ade9884 100644 --- a/lodash.keys/package.json +++ b/lodash.keys/package.json @@ -1,6 +1,6 @@ { "name": "lodash.keys", - "version": "4.0.1", + "version": "4.0.2", "description": "The lodash method `_.keys` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", diff --git a/lodash.keysin/README.md b/lodash.keysin/README.md index 588fe19b3..5a53687fe 100644 --- a/lodash.keysin/README.md +++ b/lodash.keysin/README.md @@ -1,4 +1,4 @@ -# lodash.keysin v4.0.1 +# lodash.keysin v4.0.2 The [lodash](https://lodash.com/) method `_.keysIn` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var keysIn = require('lodash.keysin'); ``` -See the [documentation](https://lodash.com/docs#keysIn) or [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash.keysin) for more details. +See the [documentation](https://lodash.com/docs#keysIn) or [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash.keysin) for more details. diff --git a/lodash.keysin/index.js b/lodash.keysin/index.js index 76a773c40..17c4aef42 100644 --- a/lodash.keysin/index.js +++ b/lodash.keysin/index.js @@ -1,5 +1,5 @@ /** - * lodash 4.0.1 (Custom Build) + * lodash 4.0.2 (Custom Build) * Build: `lodash modularize exports="npm" -o ./` * Copyright 2012-2016 The Dojo Foundation * Based on Underscore.js 1.8.3 @@ -19,6 +19,38 @@ var argsTag = '[object Arguments]', /** Used to detect unsigned integer values. */ var reIsUint = /^(?:0|[1-9]\d*)$/; +/** Used to determine if values are of the language type `Object`. */ +var objectTypes = { + 'function': true, + 'object': true +}; + +/** Detect free variable `exports`. */ +var freeExports = (objectTypes[typeof exports] && exports && !exports.nodeType) ? exports : null; + +/** Detect free variable `module`. */ +var freeModule = (objectTypes[typeof module] && module && !module.nodeType) ? module : null; + +/** Detect free variable `global` from Node.js. */ +var freeGlobal = checkGlobal(freeExports && freeModule && typeof global == 'object' && global); + +/** Detect free variable `self`. */ +var freeSelf = checkGlobal(objectTypes[typeof self] && self); + +/** Detect free variable `window`. */ +var freeWindow = checkGlobal(objectTypes[typeof window] && window); + +/** Detect `this` as the global object. */ +var thisGlobal = checkGlobal(objectTypes[typeof this] && this); + +/** + * Used as a reference to the global object. + * + * The `this` value is used if it's the global object to avoid Greasemonkey's + * restricted `window` object, otherwise the `window` object is used. + */ +var root = freeGlobal || ((freeWindow !== (thisGlobal && thisGlobal.window)) && freeWindow) || freeSelf || thisGlobal || Function('return this')(); + /** * The base implementation of `_.times` without support for iteratee shorthands * or max array length checks. @@ -38,6 +70,17 @@ function baseTimes(n, iteratee) { return result; } +/** + * Checks if `value` is a global object. + * + * @private + * @param {*} value The value to check. + * @returns {null|Object} Returns `value` if it's a global object, else `null`. + */ +function checkGlobal(value) { + return (value && value.Object === Object) ? value : null; +} + /** * Checks if `value` is a valid array-like index. * @@ -70,7 +113,7 @@ function iteratorToArray(iterator) { } /** Used for built-in method references. */ -var objectProto = global.Object.prototype; +var objectProto = Object.prototype; /** Used to check objects for own properties. */ var hasOwnProperty = objectProto.hasOwnProperty; @@ -82,7 +125,7 @@ var hasOwnProperty = objectProto.hasOwnProperty; var objectToString = objectProto.toString; /** Built-in value references. */ -var Reflect = global.Reflect, +var Reflect = root.Reflect, enumerate = Reflect ? Reflect.enumerate : undefined, propertyIsEnumerable = objectProto.propertyIsEnumerable; diff --git a/lodash.keysin/package.json b/lodash.keysin/package.json index 8af941cd9..808025d74 100644 --- a/lodash.keysin/package.json +++ b/lodash.keysin/package.json @@ -1,6 +1,6 @@ { "name": "lodash.keysin", - "version": "4.0.1", + "version": "4.0.2", "description": "The lodash method `_.keysIn` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", diff --git a/lodash.lastindexof/LICENSE b/lodash.lastindexof/LICENSE index b054ca5a3..e0c69d560 100644 --- a/lodash.lastindexof/LICENSE +++ b/lodash.lastindexof/LICENSE @@ -1,7 +1,17 @@ -Copyright 2012-2016 The Dojo Foundation -Based on Underscore.js, copyright 2009-2016 Jeremy Ashkenas, +Copyright jQuery Foundation and other contributors + +Based on Underscore.js, copyright Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors +This software consists of voluntary contributions made by many +individuals. For exact contribution history, see the revision history +available at https://github.com/lodash/lodash + +The following license applies to all parts of this software except as +documented below: + +==== + Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including @@ -20,3 +30,18 @@ NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + +==== + +Copyright and related rights for sample code are waived via CC0. Sample +code is defined as all source code displayed within the prose of the +documentation. + +CC0: http://creativecommons.org/publicdomain/zero/1.0/ + +==== + +Files located in the node_modules and vendor directories are externally +maintained libraries used by this software which have their own +licenses; we recommend you read them, as their terms may differ from the +terms above. diff --git a/lodash.lastindexof/README.md b/lodash.lastindexof/README.md index f7cf7a921..c8c6e4d08 100644 --- a/lodash.lastindexof/README.md +++ b/lodash.lastindexof/README.md @@ -1,4 +1,4 @@ -# lodash.lastindexof v4.0.1 +# lodash.lastindexof v4.0.2 The [lodash](https://lodash.com/) method `_.lastIndexOf` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var lastIndexOf = require('lodash.lastindexof'); ``` -See the [documentation](https://lodash.com/docs#lastIndexOf) or [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash.lastindexof) for more details. +See the [documentation](https://lodash.com/docs#lastIndexOf) or [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash.lastindexof) for more details. diff --git a/lodash.lastindexof/index.js b/lodash.lastindexof/index.js index 9ee556fed..b5e4ef1a5 100644 --- a/lodash.lastindexof/index.js +++ b/lodash.lastindexof/index.js @@ -1,10 +1,10 @@ /** - * lodash 4.0.1 (Custom Build) + * lodash 4.0.2 (Custom Build) * Build: `lodash modularize exports="npm" -o ./` - * Copyright 2012-2016 The Dojo Foundation + * Copyright jQuery Foundation and other contributors + * Released under MIT license * Based on Underscore.js 1.8.3 - * Copyright 2009-2016 Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors - * Available under MIT license + * Copyright Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors */ /** Used as references for various `Number` constants. */ @@ -14,7 +14,8 @@ var INFINITY = 1 / 0, /** `Object#toString` result references. */ var funcTag = '[object Function]', - genTag = '[object GeneratorFunction]'; + genTag = '[object GeneratorFunction]', + symbolTag = '[object Symbol]'; /** Used to match leading and trailing whitespace. */ var reTrim = /^\s+|\s+$/g; @@ -57,7 +58,8 @@ function indexOfNaN(array, fromIndex, fromRight) { var objectProto = Object.prototype; /** - * Used to resolve the [`toStringTag`](http://ecma-international.org/ecma-262/6.0/#sec-object.prototype.tostring) + * Used to resolve the + * [`toStringTag`](http://ecma-international.org/ecma-262/6.0/#sec-object.prototype.tostring) * of values. */ var objectToString = objectProto.toString; @@ -72,6 +74,7 @@ var nativeMax = Math.max, * * @static * @memberOf _ + * @since 0.1.0 * @category Array * @param {Array} array The array to search. * @param {*} value The value to search for. @@ -94,7 +97,11 @@ function lastIndexOf(array, value, fromIndex) { var index = length; if (fromIndex !== undefined) { index = toInteger(fromIndex); - index = (index < 0 ? nativeMax(length + index, 0) : nativeMin(index, length - 1)) + 1; + index = ( + index < 0 + ? nativeMax(length + index, 0) + : nativeMin(index, length - 1) + ) + 1; } if (value !== value) { return indexOfNaN(array, index, true); @@ -112,9 +119,11 @@ function lastIndexOf(array, value, fromIndex) { * * @static * @memberOf _ + * @since 0.1.0 * @category Lang * @param {*} value The value to check. - * @returns {boolean} Returns `true` if `value` is correctly classified, else `false`. + * @returns {boolean} Returns `true` if `value` is correctly classified, + * else `false`. * @example * * _.isFunction(_); @@ -132,11 +141,13 @@ function isFunction(value) { } /** - * Checks if `value` is the [language type](https://es5.github.io/#x8) of `Object`. - * (e.g. arrays, functions, objects, regexes, `new Number(0)`, and `new String('')`) + * Checks if `value` is the + * [language type](http://www.ecma-international.org/ecma-262/6.0/#sec-ecmascript-language-types) + * of `Object`. (e.g. arrays, functions, objects, regexes, `new Number(0)`, and `new String('')`) * * @static * @memberOf _ + * @since 0.1.0 * @category Lang * @param {*} value The value to check. * @returns {boolean} Returns `true` if `value` is an object, else `false`. @@ -160,12 +171,65 @@ function isObject(value) { } /** - * Converts `value` to an integer. - * - * **Note:** This function is loosely based on [`ToInteger`](http://www.ecma-international.org/ecma-262/6.0/#sec-tointeger). + * Checks if `value` is object-like. A value is object-like if it's not `null` + * and has a `typeof` result of "object". * * @static * @memberOf _ + * @since 4.0.0 + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is object-like, else `false`. + * @example + * + * _.isObjectLike({}); + * // => true + * + * _.isObjectLike([1, 2, 3]); + * // => true + * + * _.isObjectLike(_.noop); + * // => false + * + * _.isObjectLike(null); + * // => false + */ +function isObjectLike(value) { + return !!value && typeof value == 'object'; +} + +/** + * Checks if `value` is classified as a `Symbol` primitive or object. + * + * @static + * @memberOf _ + * @since 4.0.0 + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is correctly classified, + * else `false`. + * @example + * + * _.isSymbol(Symbol.iterator); + * // => true + * + * _.isSymbol('abc'); + * // => false + */ +function isSymbol(value) { + return typeof value == 'symbol' || + (isObjectLike(value) && objectToString.call(value) == symbolTag); +} + +/** + * Converts `value` to an integer. + * + * **Note:** This function is loosely based on + * [`ToInteger`](http://www.ecma-international.org/ecma-262/6.0/#sec-tointeger). + * + * @static + * @memberOf _ + * @since 4.0.0 * @category Lang * @param {*} value The value to convert. * @returns {number} Returns the converted integer. @@ -201,6 +265,7 @@ function toInteger(value) { * * @static * @memberOf _ + * @since 4.0.0 * @category Lang * @param {*} value The value to process. * @returns {number} Returns the number. @@ -219,6 +284,12 @@ function toInteger(value) { * // => 3 */ function toNumber(value) { + if (typeof value == 'number') { + return value; + } + if (isSymbol(value)) { + return NAN; + } if (isObject(value)) { var other = isFunction(value.valueOf) ? value.valueOf() : value; value = isObject(other) ? (other + '') : other; diff --git a/lodash.lastindexof/package.json b/lodash.lastindexof/package.json index 7d613034b..638cfc169 100644 --- a/lodash.lastindexof/package.json +++ b/lodash.lastindexof/package.json @@ -1,6 +1,6 @@ { "name": "lodash.lastindexof", - "version": "4.0.1", + "version": "4.0.2", "description": "The lodash method `_.lastIndexOf` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", @@ -9,7 +9,7 @@ "author": "John-David Dalton (http://allyoucanleet.com/)", "contributors": [ "John-David Dalton (http://allyoucanleet.com/)", - "Blaine Bublitz (https://github.com/phated)", + "Blaine Bublitz (https://github.com/phated)", "Mathias Bynens (https://mathiasbynens.be/)" ], "repository": "lodash/lodash", diff --git a/lodash.lowerfirst/README.md b/lodash.lowerfirst/README.md index fa4d78297..9253e4584 100644 --- a/lodash.lowerfirst/README.md +++ b/lodash.lowerfirst/README.md @@ -1,4 +1,4 @@ -# lodash.lowerfirst v4.0.1 +# lodash.lowerfirst v4.0.2 The [lodash](https://lodash.com/) method `_.lowerFirst` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var lowerFirst = require('lodash.lowerfirst'); ``` -See the [documentation](https://lodash.com/docs#lowerFirst) or [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash.lowerfirst) for more details. +See the [documentation](https://lodash.com/docs#lowerFirst) or [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash.lowerfirst) for more details. diff --git a/lodash.lowerfirst/index.js b/lodash.lowerfirst/index.js index 207c571cd..fe85c9081 100644 --- a/lodash.lowerfirst/index.js +++ b/lodash.lowerfirst/index.js @@ -1,5 +1,5 @@ /** - * lodash 4.0.1 (Custom Build) + * lodash 4.0.2 (Custom Build) * Build: `lodash modularize exports="npm" -o ./` * Copyright 2012-2016 The Dojo Foundation * Based on Underscore.js 1.8.3 @@ -42,6 +42,49 @@ var reComplexSymbol = RegExp(rsFitz + '(?=' + rsFitz + ')|' + rsSymbol + rsSeq, /** Used to detect strings with [zero-width joiners or code points from the astral planes](http://eev.ee/blog/2015/09/12/dark-corners-of-unicode/). */ var reHasComplexSymbol = RegExp('[' + rsZWJ + rsAstralRange + rsComboMarksRange + rsComboSymbolsRange + rsVarRange + ']'); +/** Used to determine if values are of the language type `Object`. */ +var objectTypes = { + 'function': true, + 'object': true +}; + +/** Detect free variable `exports`. */ +var freeExports = (objectTypes[typeof exports] && exports && !exports.nodeType) ? exports : null; + +/** Detect free variable `module`. */ +var freeModule = (objectTypes[typeof module] && module && !module.nodeType) ? module : null; + +/** Detect free variable `global` from Node.js. */ +var freeGlobal = checkGlobal(freeExports && freeModule && typeof global == 'object' && global); + +/** Detect free variable `self`. */ +var freeSelf = checkGlobal(objectTypes[typeof self] && self); + +/** Detect free variable `window`. */ +var freeWindow = checkGlobal(objectTypes[typeof window] && window); + +/** Detect `this` as the global object. */ +var thisGlobal = checkGlobal(objectTypes[typeof this] && this); + +/** + * Used as a reference to the global object. + * + * The `this` value is used if it's the global object to avoid Greasemonkey's + * restricted `window` object, otherwise the `window` object is used. + */ +var root = freeGlobal || ((freeWindow !== (thisGlobal && thisGlobal.window)) && freeWindow) || freeSelf || thisGlobal || Function('return this')(); + +/** + * Checks if `value` is a global object. + * + * @private + * @param {*} value The value to check. + * @returns {null|Object} Returns `value` if it's a global object, else `null`. + */ +function checkGlobal(value) { + return (value && value.Object === Object) ? value : null; +} + /** * Converts `string` to an array. * @@ -54,7 +97,7 @@ function stringToArray(string) { } /** Used for built-in method references. */ -var objectProto = global.Object.prototype; +var objectProto = Object.prototype; /** * Used to resolve the [`toStringTag`](http://ecma-international.org/ecma-262/6.0/#sec-object.prototype.tostring) @@ -63,7 +106,7 @@ var objectProto = global.Object.prototype; var objectToString = objectProto.toString; /** Built-in value references. */ -var Symbol = global.Symbol; +var Symbol = root.Symbol; /** Used to convert symbols to primitives and strings. */ var symbolProto = Symbol ? Symbol.prototype : undefined, diff --git a/lodash.lowerfirst/package.json b/lodash.lowerfirst/package.json index b8c313c22..147c73a24 100644 --- a/lodash.lowerfirst/package.json +++ b/lodash.lowerfirst/package.json @@ -1,11 +1,11 @@ { "name": "lodash.lowerfirst", - "version": "4.0.1", + "version": "4.0.2", "description": "The lodash method `_.lowerFirst` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", "license": "MIT", - "keywords": "lodash, lodash-modularized, stdlib, util, lowerfirst", + "keywords": "lodash-modularized, lowerfirst", "author": "John-David Dalton (http://allyoucanleet.com/)", "contributors": [ "John-David Dalton (http://allyoucanleet.com/)", diff --git a/lodash.map/README.md b/lodash.map/README.md index 347e1c0d6..31becf9df 100644 --- a/lodash.map/README.md +++ b/lodash.map/README.md @@ -1,4 +1,4 @@ -# lodash.map v4.0.1 +# lodash.map v4.0.2 The [lodash](https://lodash.com/) method `_.map` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var map = require('lodash.map'); ``` -See the [documentation](https://lodash.com/docs#map) or [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash.map) for more details. +See the [documentation](https://lodash.com/docs#map) or [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash.map) for more details. diff --git a/lodash.map/index.js b/lodash.map/index.js index 8d7a067b3..1fc8f9662 100644 --- a/lodash.map/index.js +++ b/lodash.map/index.js @@ -1,5 +1,5 @@ /** - * lodash 4.0.1 (Custom Build) + * lodash 4.0.2 (Custom Build) * Build: `lodash modularize exports="npm" -o ./` * Copyright 2012-2016 The Dojo Foundation * Based on Underscore.js 1.8.3 @@ -35,8 +35,51 @@ var reIsDeepProp = /\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/, /** Used to match backslashes in property paths. */ var reEscapeChar = /\\(\\)?/g; +/** Used to determine if values are of the language type `Object`. */ +var objectTypes = { + 'function': true, + 'object': true +}; + +/** Detect free variable `exports`. */ +var freeExports = (objectTypes[typeof exports] && exports && !exports.nodeType) ? exports : null; + +/** Detect free variable `module`. */ +var freeModule = (objectTypes[typeof module] && module && !module.nodeType) ? module : null; + +/** Detect free variable `global` from Node.js. */ +var freeGlobal = checkGlobal(freeExports && freeModule && typeof global == 'object' && global); + +/** Detect free variable `self`. */ +var freeSelf = checkGlobal(objectTypes[typeof self] && self); + +/** Detect free variable `window`. */ +var freeWindow = checkGlobal(objectTypes[typeof window] && window); + +/** Detect `this` as the global object. */ +var thisGlobal = checkGlobal(objectTypes[typeof this] && this); + +/** + * Used as a reference to the global object. + * + * The `this` value is used if it's the global object to avoid Greasemonkey's + * restricted `window` object, otherwise the `window` object is used. + */ +var root = freeGlobal || ((freeWindow !== (thisGlobal && thisGlobal.window)) && freeWindow) || freeSelf || thisGlobal || Function('return this')(); + +/** + * Checks if `value` is a global object. + * + * @private + * @param {*} value The value to check. + * @returns {null|Object} Returns `value` if it's a global object, else `null`. + */ +function checkGlobal(value) { + return (value && value.Object === Object) ? value : null; +} + /** Used for built-in method references. */ -var objectProto = global.Object.prototype; +var objectProto = Object.prototype; /** * Used to resolve the [`toStringTag`](http://ecma-international.org/ecma-262/6.0/#sec-object.prototype.tostring) @@ -45,7 +88,7 @@ var objectProto = global.Object.prototype; var objectToString = objectProto.toString; /** Built-in value references. */ -var Symbol = global.Symbol; +var Symbol = root.Symbol; /** Used to convert symbols to primitives and strings. */ var symbolProto = Symbol ? Symbol.prototype : undefined, @@ -303,7 +346,7 @@ function stringToPath(string) { * { 'user': 'fred' } * ]; * - * // using the `_.property` iteratee shorthand + * // The `_.property` iteratee shorthand. * _.map(users, 'user'); * // => ['barney', 'fred'] */ diff --git a/lodash.map/package.json b/lodash.map/package.json index c80e3e3e8..989c0a32d 100644 --- a/lodash.map/package.json +++ b/lodash.map/package.json @@ -1,11 +1,11 @@ { "name": "lodash.map", - "version": "4.0.1", + "version": "4.0.2", "description": "The lodash method `_.map` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", "license": "MIT", - "keywords": "lodash, lodash-modularized, stdlib, util, map", + "keywords": "lodash-modularized, map", "author": "John-David Dalton (http://allyoucanleet.com/)", "contributors": [ "John-David Dalton (http://allyoucanleet.com/)", diff --git a/lodash.mapkeys/README.md b/lodash.mapkeys/README.md index 29a3696af..eb9351d86 100644 --- a/lodash.mapkeys/README.md +++ b/lodash.mapkeys/README.md @@ -1,4 +1,4 @@ -# lodash.mapkeys v4.0.1 +# lodash.mapkeys v4.0.2 The [lodash](https://lodash.com/) method `_.mapKeys` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var mapKeys = require('lodash.mapkeys'); ``` -See the [documentation](https://lodash.com/docs#mapKeys) or [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash.mapkeys) for more details. +See the [documentation](https://lodash.com/docs#mapKeys) or [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash.mapkeys) for more details. diff --git a/lodash.mapkeys/index.js b/lodash.mapkeys/index.js index cb187f7b9..0aea873a4 100644 --- a/lodash.mapkeys/index.js +++ b/lodash.mapkeys/index.js @@ -1,5 +1,5 @@ /** - * lodash 4.0.1 (Custom Build) + * lodash 4.0.2 (Custom Build) * Build: `lodash modularize exports="npm" -o ./` * Copyright 2012-2016 The Dojo Foundation * Based on Underscore.js 1.8.3 @@ -32,8 +32,51 @@ var reIsDeepProp = /\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/, /** Used to match backslashes in property paths. */ var reEscapeChar = /\\(\\)?/g; +/** Used to determine if values are of the language type `Object`. */ +var objectTypes = { + 'function': true, + 'object': true +}; + +/** Detect free variable `exports`. */ +var freeExports = (objectTypes[typeof exports] && exports && !exports.nodeType) ? exports : null; + +/** Detect free variable `module`. */ +var freeModule = (objectTypes[typeof module] && module && !module.nodeType) ? module : null; + +/** Detect free variable `global` from Node.js. */ +var freeGlobal = checkGlobal(freeExports && freeModule && typeof global == 'object' && global); + +/** Detect free variable `self`. */ +var freeSelf = checkGlobal(objectTypes[typeof self] && self); + +/** Detect free variable `window`. */ +var freeWindow = checkGlobal(objectTypes[typeof window] && window); + +/** Detect `this` as the global object. */ +var thisGlobal = checkGlobal(objectTypes[typeof this] && this); + +/** + * Used as a reference to the global object. + * + * The `this` value is used if it's the global object to avoid Greasemonkey's + * restricted `window` object, otherwise the `window` object is used. + */ +var root = freeGlobal || ((freeWindow !== (thisGlobal && thisGlobal.window)) && freeWindow) || freeSelf || thisGlobal || Function('return this')(); + +/** + * Checks if `value` is a global object. + * + * @private + * @param {*} value The value to check. + * @returns {null|Object} Returns `value` if it's a global object, else `null`. + */ +function checkGlobal(value) { + return (value && value.Object === Object) ? value : null; +} + /** Used for built-in method references. */ -var objectProto = global.Object.prototype; +var objectProto = Object.prototype; /** * Used to resolve the [`toStringTag`](http://ecma-international.org/ecma-262/6.0/#sec-object.prototype.tostring) @@ -42,7 +85,7 @@ var objectProto = global.Object.prototype; var objectToString = objectProto.toString; /** Built-in value references. */ -var Symbol = global.Symbol; +var Symbol = root.Symbol; /** Used to convert symbols to primitives and strings. */ var symbolProto = Symbol ? Symbol.prototype : undefined, diff --git a/lodash.mapkeys/package.json b/lodash.mapkeys/package.json index 8fb67762d..7695d9df3 100644 --- a/lodash.mapkeys/package.json +++ b/lodash.mapkeys/package.json @@ -1,11 +1,11 @@ { "name": "lodash.mapkeys", - "version": "4.0.1", + "version": "4.0.2", "description": "The lodash method `_.mapKeys` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", "license": "MIT", - "keywords": "lodash, lodash-modularized, stdlib, util, mapkeys", + "keywords": "lodash-modularized, mapkeys", "author": "John-David Dalton (http://allyoucanleet.com/)", "contributors": [ "John-David Dalton (http://allyoucanleet.com/)", diff --git a/lodash.mapvalues/README.md b/lodash.mapvalues/README.md index 12e0dc817..a991233f3 100644 --- a/lodash.mapvalues/README.md +++ b/lodash.mapvalues/README.md @@ -1,4 +1,4 @@ -# lodash.mapvalues v4.0.1 +# lodash.mapvalues v4.0.2 The [lodash](https://lodash.com/) method `_.mapValues` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var mapValues = require('lodash.mapvalues'); ``` -See the [documentation](https://lodash.com/docs#mapValues) or [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash.mapvalues) for more details. +See the [documentation](https://lodash.com/docs#mapValues) or [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash.mapvalues) for more details. diff --git a/lodash.mapvalues/index.js b/lodash.mapvalues/index.js index e324894c7..ff827684e 100644 --- a/lodash.mapvalues/index.js +++ b/lodash.mapvalues/index.js @@ -1,5 +1,5 @@ /** - * lodash 4.0.1 (Custom Build) + * lodash 4.0.2 (Custom Build) * Build: `lodash modularize exports="npm" -o ./` * Copyright 2012-2016 The Dojo Foundation * Based on Underscore.js 1.8.3 @@ -32,8 +32,51 @@ var reIsDeepProp = /\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/, /** Used to match backslashes in property paths. */ var reEscapeChar = /\\(\\)?/g; +/** Used to determine if values are of the language type `Object`. */ +var objectTypes = { + 'function': true, + 'object': true +}; + +/** Detect free variable `exports`. */ +var freeExports = (objectTypes[typeof exports] && exports && !exports.nodeType) ? exports : null; + +/** Detect free variable `module`. */ +var freeModule = (objectTypes[typeof module] && module && !module.nodeType) ? module : null; + +/** Detect free variable `global` from Node.js. */ +var freeGlobal = checkGlobal(freeExports && freeModule && typeof global == 'object' && global); + +/** Detect free variable `self`. */ +var freeSelf = checkGlobal(objectTypes[typeof self] && self); + +/** Detect free variable `window`. */ +var freeWindow = checkGlobal(objectTypes[typeof window] && window); + +/** Detect `this` as the global object. */ +var thisGlobal = checkGlobal(objectTypes[typeof this] && this); + +/** + * Used as a reference to the global object. + * + * The `this` value is used if it's the global object to avoid Greasemonkey's + * restricted `window` object, otherwise the `window` object is used. + */ +var root = freeGlobal || ((freeWindow !== (thisGlobal && thisGlobal.window)) && freeWindow) || freeSelf || thisGlobal || Function('return this')(); + +/** + * Checks if `value` is a global object. + * + * @private + * @param {*} value The value to check. + * @returns {null|Object} Returns `value` if it's a global object, else `null`. + */ +function checkGlobal(value) { + return (value && value.Object === Object) ? value : null; +} + /** Used for built-in method references. */ -var objectProto = global.Object.prototype; +var objectProto = Object.prototype; /** * Used to resolve the [`toStringTag`](http://ecma-international.org/ecma-262/6.0/#sec-object.prototype.tostring) @@ -42,7 +85,7 @@ var objectProto = global.Object.prototype; var objectToString = objectProto.toString; /** Built-in value references. */ -var Symbol = global.Symbol; +var Symbol = root.Symbol; /** Used to convert symbols to primitives and strings. */ var symbolProto = Symbol ? Symbol.prototype : undefined, @@ -402,7 +445,7 @@ function toString(value) { * _.mapValues(users, function(o) { return o.age; }); * // => { 'fred': 40, 'pebbles': 1 } (iteration order is not guaranteed) * - * // using the `_.property` iteratee shorthand + * // The `_.property` iteratee shorthand. * _.mapValues(users, 'age'); * // => { 'fred': 40, 'pebbles': 1 } (iteration order is not guaranteed) */ diff --git a/lodash.mapvalues/package.json b/lodash.mapvalues/package.json index 4399dff64..4f8834b53 100644 --- a/lodash.mapvalues/package.json +++ b/lodash.mapvalues/package.json @@ -1,11 +1,11 @@ { "name": "lodash.mapvalues", - "version": "4.0.1", + "version": "4.0.2", "description": "The lodash method `_.mapValues` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", "license": "MIT", - "keywords": "lodash, lodash-modularized, stdlib, util, mapvalues", + "keywords": "lodash-modularized, mapvalues", "author": "John-David Dalton (http://allyoucanleet.com/)", "contributors": [ "John-David Dalton (http://allyoucanleet.com/)", diff --git a/lodash.matches/README.md b/lodash.matches/README.md index dfd16315b..95eae2117 100644 --- a/lodash.matches/README.md +++ b/lodash.matches/README.md @@ -1,4 +1,4 @@ -# lodash.matches v4.0.1 +# lodash.matches v4.0.2 The [lodash](https://lodash.com/) method `_.matches` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var matches = require('lodash.matches'); ``` -See the [documentation](https://lodash.com/docs#matches) or [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash.matches) for more details. +See the [documentation](https://lodash.com/docs#matches) or [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash.matches) for more details. diff --git a/lodash.matches/index.js b/lodash.matches/index.js index 98db0e1e6..5fd8f8672 100644 --- a/lodash.matches/index.js +++ b/lodash.matches/index.js @@ -1,5 +1,5 @@ /** - * lodash 4.0.0 (Custom Build) + * lodash 4.0.2 (Custom Build) * Build: `lodash modularize exports="npm" -o ./` * Copyright 2012-2016 The Dojo Foundation * Based on Underscore.js 1.8.3 @@ -100,14 +100,14 @@ function addSetEntry(set, value) { * @param {Array} array The array to iterate over. * @param {Function} iteratee The function invoked per iteration. * @param {*} [accumulator] The initial value. - * @param {boolean} [initFromArray] Specify using the first element of `array` as the initial value. + * @param {boolean} [initAccum] Specify using the first element of `array` as the initial value. * @returns {*} Returns the accumulated value. */ -function arrayReduce(array, iteratee, accumulator, initFromArray) { +function arrayReduce(array, iteratee, accumulator, initAccum) { var index = -1, length = array.length; - if (initFromArray && length) { + if (initAccum && length) { accumulator = array[++index]; } while (++index < length) { @@ -191,7 +191,7 @@ var reIsNative = RegExp('^' + ); /** Built-in value references. */ -var _Symbol = global.Symbol, +var Symbol = global.Symbol, Uint8Array = global.Uint8Array, getOwnPropertySymbols = Object.getOwnPropertySymbols; @@ -204,8 +204,8 @@ var mapCtorString = Map ? funcToString.call(Map) : '', setCtorString = Set ? funcToString.call(Set) : ''; /** Used to convert symbols to primitives and strings. */ -var symbolProto = _Symbol ? _Symbol.prototype : undefined, - symbolValueOf = _Symbol ? symbolProto.valueOf : undefined; +var symbolProto = Symbol ? Symbol.prototype : undefined, + symbolValueOf = Symbol ? symbolProto.valueOf : undefined; /** * Assigns `value` to `key` of `object` if the existing value is not equivalent @@ -423,7 +423,7 @@ function cloneSet(set) { * @returns {Object} Returns the cloned symbol object. */ function cloneSymbol(symbol) { - return _Symbol ? Object(symbolValueOf.call(symbol)) : {}; + return Symbol ? Object(symbolValueOf.call(symbol)) : {}; } /** diff --git a/lodash.matches/package.json b/lodash.matches/package.json index 71f8d5f5e..e04ed6fb4 100644 --- a/lodash.matches/package.json +++ b/lodash.matches/package.json @@ -1,6 +1,6 @@ { "name": "lodash.matches", - "version": "4.0.1", + "version": "4.0.2", "description": "The lodash method `_.matches` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", diff --git a/lodash.matchesproperty/README.md b/lodash.matchesproperty/README.md index e8c4cad6d..83d6a6a6f 100644 --- a/lodash.matchesproperty/README.md +++ b/lodash.matchesproperty/README.md @@ -1,4 +1,4 @@ -# lodash.matchesproperty v4.0.1 +# lodash.matchesproperty v4.0.2 The [lodash](https://lodash.com/) method `_.matchesProperty` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var matchesProperty = require('lodash.matchesproperty'); ``` -See the [documentation](https://lodash.com/docs#matchesProperty) or [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash.matchesproperty) for more details. +See the [documentation](https://lodash.com/docs#matchesProperty) or [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash.matchesproperty) for more details. diff --git a/lodash.matchesproperty/index.js b/lodash.matchesproperty/index.js index 05160f704..eb9704169 100644 --- a/lodash.matchesproperty/index.js +++ b/lodash.matchesproperty/index.js @@ -1,5 +1,5 @@ /** - * lodash 4.0.0 (Custom Build) + * lodash 4.0.2 (Custom Build) * Build: `lodash modularize exports="npm" -o ./` * Copyright 2012-2016 The Dojo Foundation * Based on Underscore.js 1.8.3 @@ -105,14 +105,14 @@ function addSetEntry(set, value) { * @param {Array} array The array to iterate over. * @param {Function} iteratee The function invoked per iteration. * @param {*} [accumulator] The initial value. - * @param {boolean} [initFromArray] Specify using the first element of `array` as the initial value. + * @param {boolean} [initAccum] Specify using the first element of `array` as the initial value. * @returns {*} Returns the accumulated value. */ -function arrayReduce(array, iteratee, accumulator, initFromArray) { +function arrayReduce(array, iteratee, accumulator, initAccum) { var index = -1, length = array.length; - if (initFromArray && length) { + if (initAccum && length) { accumulator = array[++index]; } while (++index < length) { @@ -196,7 +196,7 @@ var reIsNative = RegExp('^' + ); /** Built-in value references. */ -var _Symbol = global.Symbol, +var Symbol = global.Symbol, Uint8Array = global.Uint8Array, getOwnPropertySymbols = Object.getOwnPropertySymbols; @@ -209,8 +209,8 @@ var mapCtorString = Map ? funcToString.call(Map) : '', setCtorString = Set ? funcToString.call(Set) : ''; /** Used to convert symbols to primitives and strings. */ -var symbolProto = _Symbol ? _Symbol.prototype : undefined, - symbolValueOf = _Symbol ? symbolProto.valueOf : undefined; +var symbolProto = Symbol ? Symbol.prototype : undefined, + symbolValueOf = Symbol ? symbolProto.valueOf : undefined; /** * Assigns `value` to `key` of `object` if the existing value is not equivalent @@ -419,7 +419,7 @@ function cloneSet(set) { * @returns {Object} Returns the cloned symbol object. */ function cloneSymbol(symbol) { - return _Symbol ? Object(symbolValueOf.call(symbol)) : {}; + return Symbol ? Object(symbolValueOf.call(symbol)) : {}; } /** diff --git a/lodash.matchesproperty/package.json b/lodash.matchesproperty/package.json index ebc008cd7..af3a13bf4 100644 --- a/lodash.matchesproperty/package.json +++ b/lodash.matchesproperty/package.json @@ -1,6 +1,6 @@ { "name": "lodash.matchesproperty", - "version": "4.0.1", + "version": "4.0.2", "description": "The lodash method `_.matchesProperty` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", diff --git a/lodash.maxby/README.md b/lodash.maxby/README.md index e990de8d6..6c81c12e5 100644 --- a/lodash.maxby/README.md +++ b/lodash.maxby/README.md @@ -1,4 +1,4 @@ -# lodash.maxby v4.0.1 +# lodash.maxby v4.0.2 The [lodash](https://lodash.com/) method `_.maxBy` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var maxBy = require('lodash.maxby'); ``` -See the [documentation](https://lodash.com/docs#maxBy) or [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash.maxby) for more details. +See the [documentation](https://lodash.com/docs#maxBy) or [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash.maxby) for more details. diff --git a/lodash.maxby/index.js b/lodash.maxby/index.js index 12ddfa355..8847526d8 100644 --- a/lodash.maxby/index.js +++ b/lodash.maxby/index.js @@ -1,5 +1,5 @@ /** - * lodash 4.0.1 (Custom Build) + * lodash 4.0.2 (Custom Build) * Build: `lodash modularize exports="npm" -o ./` * Copyright 2012-2016 The Dojo Foundation * Based on Underscore.js 1.8.3 @@ -30,6 +30,38 @@ var reIsDeepProp = /\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/, /** Used to match backslashes in property paths. */ var reEscapeChar = /\\(\\)?/g; +/** Used to determine if values are of the language type `Object`. */ +var objectTypes = { + 'function': true, + 'object': true +}; + +/** Detect free variable `exports`. */ +var freeExports = (objectTypes[typeof exports] && exports && !exports.nodeType) ? exports : null; + +/** Detect free variable `module`. */ +var freeModule = (objectTypes[typeof module] && module && !module.nodeType) ? module : null; + +/** Detect free variable `global` from Node.js. */ +var freeGlobal = checkGlobal(freeExports && freeModule && typeof global == 'object' && global); + +/** Detect free variable `self`. */ +var freeSelf = checkGlobal(objectTypes[typeof self] && self); + +/** Detect free variable `window`. */ +var freeWindow = checkGlobal(objectTypes[typeof window] && window); + +/** Detect `this` as the global object. */ +var thisGlobal = checkGlobal(objectTypes[typeof this] && this); + +/** + * Used as a reference to the global object. + * + * The `this` value is used if it's the global object to avoid Greasemonkey's + * restricted `window` object, otherwise the `window` object is used. + */ +var root = freeGlobal || ((freeWindow !== (thisGlobal && thisGlobal.window)) && freeWindow) || freeSelf || thisGlobal || Function('return this')(); + /** * The base implementation of methods like `_.max` and `_.min` which accepts a * `comparator` to determine the extremum value. @@ -59,8 +91,19 @@ function baseExtremum(array, iteratee, comparator) { return result; } +/** + * Checks if `value` is a global object. + * + * @private + * @param {*} value The value to check. + * @returns {null|Object} Returns `value` if it's a global object, else `null`. + */ +function checkGlobal(value) { + return (value && value.Object === Object) ? value : null; +} + /** Used for built-in method references. */ -var objectProto = global.Object.prototype; +var objectProto = Object.prototype; /** * Used to resolve the [`toStringTag`](http://ecma-international.org/ecma-262/6.0/#sec-object.prototype.tostring) @@ -69,7 +112,7 @@ var objectProto = global.Object.prototype; var objectToString = objectProto.toString; /** Built-in value references. */ -var Symbol = global.Symbol; +var Symbol = root.Symbol; /** Used to convert symbols to primitives and strings. */ var symbolProto = Symbol ? Symbol.prototype : undefined, @@ -482,7 +525,7 @@ function property(path) { * _.maxBy(objects, function(o) { return o.n; }); * // => { 'n': 2 } * - * // using the `_.property` iteratee shorthand + * // The `_.property` iteratee shorthand. * _.maxBy(objects, 'n'); * // => { 'n': 2 } */ diff --git a/lodash.maxby/package.json b/lodash.maxby/package.json index 4a98c77f2..0e32505ed 100644 --- a/lodash.maxby/package.json +++ b/lodash.maxby/package.json @@ -1,11 +1,11 @@ { "name": "lodash.maxby", - "version": "4.0.1", + "version": "4.0.2", "description": "The lodash method `_.maxBy` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", "license": "MIT", - "keywords": "lodash, lodash-modularized, stdlib, util, maxby", + "keywords": "lodash-modularized, maxby", "author": "John-David Dalton (http://allyoucanleet.com/)", "contributors": [ "John-David Dalton (http://allyoucanleet.com/)", diff --git a/lodash.memoize/LICENSE b/lodash.memoize/LICENSE index b054ca5a3..bcbe13d67 100644 --- a/lodash.memoize/LICENSE +++ b/lodash.memoize/LICENSE @@ -1,22 +1,23 @@ +The MIT License (MIT) + Copyright 2012-2016 The Dojo Foundation Based on Underscore.js, copyright 2009-2016 Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors -Permission is hereby granted, free of charge, to any person obtaining -a copy of this software and associated documentation files (the -"Software"), to deal in the Software without restriction, including -without limitation the rights to use, copy, modify, merge, publish, -distribute, sublicense, and/or sell copies of the Software, and to -permit persons to whom the Software is furnished to do so, subject to -the following conditions: +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: -The above copyright notice and this permission notice shall be -included in all copies or substantial portions of the Software. +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, -EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND -NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE -LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION -OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION -WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. diff --git a/lodash.memoize/README.md b/lodash.memoize/README.md index c5173334f..fca6c0c5c 100644 --- a/lodash.memoize/README.md +++ b/lodash.memoize/README.md @@ -1,4 +1,4 @@ -# lodash.memoize v4.0.1 +# lodash.memoize v4.0.2 The [lodash](https://lodash.com/) method `_.memoize` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var memoize = require('lodash.memoize'); ``` -See the [documentation](https://lodash.com/docs#memoize) or [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash.memoize) for more details. +See the [documentation](https://lodash.com/docs#memoize) or [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash.memoize) for more details. diff --git a/lodash.memoize/index.js b/lodash.memoize/index.js index b19fed584..f7ae9c5ab 100644 --- a/lodash.memoize/index.js +++ b/lodash.memoize/index.js @@ -1,5 +1,5 @@ /** - * lodash 4.0.1 (Custom Build) + * lodash 4.0.2 (Custom Build) * Build: `lodash modularize exports="npm" -o ./` * Copyright 2012-2016 The Dojo Foundation * Based on Underscore.js 1.8.3 diff --git a/lodash.memoize/package.json b/lodash.memoize/package.json index dc7eea180..4733dba42 100644 --- a/lodash.memoize/package.json +++ b/lodash.memoize/package.json @@ -1,20 +1,20 @@ { "name": "lodash.memoize", - "version": "4.0.1", + "version": "4.0.2", "description": "The lodash method `_.memoize` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", "license": "MIT", - "keywords": "lodash, lodash-modularized, stdlib, util, memoize", + "keywords": "lodash-modularized, memoize", "author": "John-David Dalton (http://allyoucanleet.com/)", "contributors": [ "John-David Dalton (http://allyoucanleet.com/)", - "Blaine Bublitz (https://github.com/phated)", + "Blaine Bublitz (https://github.com/phated)", "Mathias Bynens (https://mathiasbynens.be/)" ], "repository": "lodash/lodash", "scripts": { "test": "echo \"See https://travis-ci.org/lodash/lodash-cli for testing details.\"" }, "dependencies": { - "lodash._mapcache": "^4.0.0" + "lodash._mapcache": "~4.1.0" } } diff --git a/lodash.merge/README.md b/lodash.merge/README.md index 4292f3c89..4453551da 100644 --- a/lodash.merge/README.md +++ b/lodash.merge/README.md @@ -1,4 +1,4 @@ -# lodash.merge v4.0.1 +# lodash.merge v4.0.2 The [lodash](https://lodash.com/) method `_.merge` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var merge = require('lodash.merge'); ``` -See the [documentation](https://lodash.com/docs#merge) or [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash.merge) for more details. +See the [documentation](https://lodash.com/docs#merge) or [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash.merge) for more details. diff --git a/lodash.merge/index.js b/lodash.merge/index.js index 192987979..b0389bbf3 100644 --- a/lodash.merge/index.js +++ b/lodash.merge/index.js @@ -1,5 +1,5 @@ /** - * lodash 4.0.0 (Custom Build) + * lodash 4.0.2 (Custom Build) * Build: `lodash modularize exports="npm" -o ./` * Copyright 2012-2016 The Dojo Foundation * Based on Underscore.js 1.8.3 @@ -122,14 +122,14 @@ function addSetEntry(set, value) { * @param {Array} array The array to iterate over. * @param {Function} iteratee The function invoked per iteration. * @param {*} [accumulator] The initial value. - * @param {boolean} [initFromArray] Specify using the first element of `array` as the initial value. + * @param {boolean} [initAccum] Specify using the first element of `array` as the initial value. * @returns {*} Returns the accumulated value. */ -function arrayReduce(array, iteratee, accumulator, initFromArray) { +function arrayReduce(array, iteratee, accumulator, initAccum) { var index = -1, length = array.length; - if (initFromArray && length) { + if (initAccum && length) { accumulator = array[++index]; } while (++index < length) { @@ -227,7 +227,7 @@ var reIsNative = RegExp('^' + ); /** Built-in value references. */ -var _Symbol = global.Symbol, +var Symbol = global.Symbol, Uint8Array = global.Uint8Array, getOwnPropertySymbols = Object.getOwnPropertySymbols, propertyIsEnumerable = objectProto.propertyIsEnumerable; @@ -241,8 +241,8 @@ var mapCtorString = Map ? funcToString.call(Map) : '', setCtorString = Set ? funcToString.call(Set) : ''; /** Used to convert symbols to primitives and strings. */ -var symbolProto = _Symbol ? _Symbol.prototype : undefined, - symbolValueOf = _Symbol ? symbolProto.valueOf : undefined; +var symbolProto = Symbol ? Symbol.prototype : undefined, + symbolValueOf = Symbol ? symbolProto.valueOf : undefined; /** * This function is like `assignValue` except that it doesn't assign `undefined` values. @@ -392,10 +392,11 @@ function baseForOwn(object, iteratee) { * @private * @param {Object} object The destination object. * @param {Object} source The source object. + * @param {number} srcIndex The index of `source`. * @param {Function} [customizer] The function to customize merged values. * @param {Object} [stack] Tracks traversed source values and their merged counterparts. */ -function baseMerge(object, source, customizer, stack) { +function baseMerge(object, source, srcIndex, customizer, stack) { if (object === source) { return; } @@ -407,7 +408,7 @@ function baseMerge(object, source, customizer, stack) { } if (isObject(srcValue)) { stack || (stack = new Stack); - baseMergeDeep(object, source, key, baseMerge, customizer, stack); + baseMergeDeep(object, source, key, srcIndex, baseMerge, customizer, stack); } else { var newValue = customizer ? customizer(object[key], srcValue, (key + ''), object, source, stack) : undefined; @@ -428,11 +429,12 @@ function baseMerge(object, source, customizer, stack) { * @param {Object} object The destination object. * @param {Object} source The source object. * @param {string} key The key of the value to merge. + * @param {number} srcIndex The index of `source`. * @param {Function} mergeFunc The function to merge values. * @param {Function} [customizer] The function to customize assigned values. * @param {Object} [stack] Tracks traversed source values and their merged counterparts. */ -function baseMergeDeep(object, source, key, mergeFunc, customizer, stack) { +function baseMergeDeep(object, source, key, srcIndex, mergeFunc, customizer, stack) { var objValue = object[key], srcValue = source[key], stacked = stack.get(srcValue) || stack.get(objValue); @@ -447,24 +449,36 @@ function baseMergeDeep(object, source, key, mergeFunc, customizer, stack) { if (isCommon) { newValue = srcValue; if (isArray(srcValue) || isTypedArray(srcValue)) { - newValue = isArray(objValue) - ? objValue - : ((isArrayLikeObject(objValue)) ? copyArray(objValue) : baseClone(srcValue)); + if (isArray(objValue)) { + newValue = srcIndex ? copyArray(objValue) : objValue; + } + else if (isArrayLikeObject(objValue)) { + newValue = copyArray(objValue); + } + else { + newValue = baseClone(srcValue); + } } else if (isPlainObject(srcValue) || isArguments(srcValue)) { - newValue = isArguments(objValue) - ? toPlainObject(objValue) - : (isObject(objValue) ? objValue : baseClone(srcValue)); + if (isArguments(objValue)) { + newValue = toPlainObject(objValue); + } + else if (!isObject(objValue) || (srcIndex && isFunction(objValue))) { + newValue = baseClone(srcValue); + } + else { + newValue = srcIndex ? baseClone(objValue) : objValue; + } } else { - isCommon = isFunction(srcValue); + isCommon = false; } } stack.set(srcValue, newValue); if (isCommon) { // Recursively merge objects and arrays (susceptible to call stack limits). - mergeFunc(newValue, srcValue, customizer, stack); + mergeFunc(newValue, srcValue, srcIndex, customizer, stack); } assignMergeValue(object, key, newValue); } @@ -545,7 +559,7 @@ function cloneSet(set) { * @returns {Object} Returns the cloned symbol object. */ function cloneSymbol(symbol) { - return _Symbol ? Object(symbolValueOf.call(symbol)) : {}; + return Symbol ? Object(symbolValueOf.call(symbol)) : {}; } /** @@ -656,7 +670,7 @@ function createAssigner(assigner) { while (++index < length) { var source = sources[index]; if (source) { - assigner(object, source, customizer); + assigner(object, source, index, customizer); } } return object; @@ -1178,8 +1192,8 @@ function toPlainObject(value) { * _.merge(users, ages); * // => { 'data': [{ 'user': 'barney', 'age': 36 }, { 'user': 'fred', 'age': 40 }] } */ -var merge = createAssigner(function(object, source) { - baseMerge(object, source); +var merge = createAssigner(function(object, source, srcIndex) { + baseMerge(object, source, srcIndex); }); module.exports = merge; diff --git a/lodash.merge/package.json b/lodash.merge/package.json index c760e9706..2ab70fb4e 100644 --- a/lodash.merge/package.json +++ b/lodash.merge/package.json @@ -1,6 +1,6 @@ { "name": "lodash.merge", - "version": "4.0.1", + "version": "4.0.2", "description": "The lodash method `_.merge` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", diff --git a/lodash.mergewith/README.md b/lodash.mergewith/README.md index 6162b8c4f..92d8e7b48 100644 --- a/lodash.mergewith/README.md +++ b/lodash.mergewith/README.md @@ -1,4 +1,4 @@ -# lodash.mergewith v4.0.1 +# lodash.mergewith v4.0.2 The [lodash](https://lodash.com/) method `_.mergeWith` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var mergeWith = require('lodash.mergewith'); ``` -See the [documentation](https://lodash.com/docs#mergeWith) or [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash.mergewith) for more details. +See the [documentation](https://lodash.com/docs#mergeWith) or [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash.mergewith) for more details. diff --git a/lodash.mergewith/index.js b/lodash.mergewith/index.js index ad2e3e69d..d981c4045 100644 --- a/lodash.mergewith/index.js +++ b/lodash.mergewith/index.js @@ -1,5 +1,5 @@ /** - * lodash 4.0.0 (Custom Build) + * lodash 4.0.2 (Custom Build) * Build: `lodash modularize exports="npm" -o ./` * Copyright 2012-2016 The Dojo Foundation * Based on Underscore.js 1.8.3 @@ -122,14 +122,14 @@ function addSetEntry(set, value) { * @param {Array} array The array to iterate over. * @param {Function} iteratee The function invoked per iteration. * @param {*} [accumulator] The initial value. - * @param {boolean} [initFromArray] Specify using the first element of `array` as the initial value. + * @param {boolean} [initAccum] Specify using the first element of `array` as the initial value. * @returns {*} Returns the accumulated value. */ -function arrayReduce(array, iteratee, accumulator, initFromArray) { +function arrayReduce(array, iteratee, accumulator, initAccum) { var index = -1, length = array.length; - if (initFromArray && length) { + if (initAccum && length) { accumulator = array[++index]; } while (++index < length) { @@ -227,7 +227,7 @@ var reIsNative = RegExp('^' + ); /** Built-in value references. */ -var _Symbol = global.Symbol, +var Symbol = global.Symbol, Uint8Array = global.Uint8Array, getOwnPropertySymbols = Object.getOwnPropertySymbols, propertyIsEnumerable = objectProto.propertyIsEnumerable; @@ -241,8 +241,8 @@ var mapCtorString = Map ? funcToString.call(Map) : '', setCtorString = Set ? funcToString.call(Set) : ''; /** Used to convert symbols to primitives and strings. */ -var symbolProto = _Symbol ? _Symbol.prototype : undefined, - symbolValueOf = _Symbol ? symbolProto.valueOf : undefined; +var symbolProto = Symbol ? Symbol.prototype : undefined, + symbolValueOf = Symbol ? symbolProto.valueOf : undefined; /** * This function is like `assignValue` except that it doesn't assign `undefined` values. @@ -392,10 +392,11 @@ function baseForOwn(object, iteratee) { * @private * @param {Object} object The destination object. * @param {Object} source The source object. + * @param {number} srcIndex The index of `source`. * @param {Function} [customizer] The function to customize merged values. * @param {Object} [stack] Tracks traversed source values and their merged counterparts. */ -function baseMerge(object, source, customizer, stack) { +function baseMerge(object, source, srcIndex, customizer, stack) { if (object === source) { return; } @@ -407,7 +408,7 @@ function baseMerge(object, source, customizer, stack) { } if (isObject(srcValue)) { stack || (stack = new Stack); - baseMergeDeep(object, source, key, baseMerge, customizer, stack); + baseMergeDeep(object, source, key, srcIndex, baseMerge, customizer, stack); } else { var newValue = customizer ? customizer(object[key], srcValue, (key + ''), object, source, stack) : undefined; @@ -428,11 +429,12 @@ function baseMerge(object, source, customizer, stack) { * @param {Object} object The destination object. * @param {Object} source The source object. * @param {string} key The key of the value to merge. + * @param {number} srcIndex The index of `source`. * @param {Function} mergeFunc The function to merge values. * @param {Function} [customizer] The function to customize assigned values. * @param {Object} [stack] Tracks traversed source values and their merged counterparts. */ -function baseMergeDeep(object, source, key, mergeFunc, customizer, stack) { +function baseMergeDeep(object, source, key, srcIndex, mergeFunc, customizer, stack) { var objValue = object[key], srcValue = source[key], stacked = stack.get(srcValue) || stack.get(objValue); @@ -447,24 +449,36 @@ function baseMergeDeep(object, source, key, mergeFunc, customizer, stack) { if (isCommon) { newValue = srcValue; if (isArray(srcValue) || isTypedArray(srcValue)) { - newValue = isArray(objValue) - ? objValue - : ((isArrayLikeObject(objValue)) ? copyArray(objValue) : baseClone(srcValue)); + if (isArray(objValue)) { + newValue = srcIndex ? copyArray(objValue) : objValue; + } + else if (isArrayLikeObject(objValue)) { + newValue = copyArray(objValue); + } + else { + newValue = baseClone(srcValue); + } } else if (isPlainObject(srcValue) || isArguments(srcValue)) { - newValue = isArguments(objValue) - ? toPlainObject(objValue) - : (isObject(objValue) ? objValue : baseClone(srcValue)); + if (isArguments(objValue)) { + newValue = toPlainObject(objValue); + } + else if (!isObject(objValue) || (srcIndex && isFunction(objValue))) { + newValue = baseClone(srcValue); + } + else { + newValue = srcIndex ? baseClone(objValue) : objValue; + } } else { - isCommon = isFunction(srcValue); + isCommon = false; } } stack.set(srcValue, newValue); if (isCommon) { // Recursively merge objects and arrays (susceptible to call stack limits). - mergeFunc(newValue, srcValue, customizer, stack); + mergeFunc(newValue, srcValue, srcIndex, customizer, stack); } assignMergeValue(object, key, newValue); } @@ -545,7 +559,7 @@ function cloneSet(set) { * @returns {Object} Returns the cloned symbol object. */ function cloneSymbol(symbol) { - return _Symbol ? Object(symbolValueOf.call(symbol)) : {}; + return Symbol ? Object(symbolValueOf.call(symbol)) : {}; } /** @@ -656,7 +670,7 @@ function createAssigner(assigner) { while (++index < length) { var source = sources[index]; if (source) { - assigner(object, source, customizer); + assigner(object, source, index, customizer); } } return object; @@ -1184,8 +1198,8 @@ function toPlainObject(value) { * _.mergeWith(object, other, customizer); * // => { 'fruits': ['apple', 'banana'], 'vegetables': ['beet', 'carrot'] } */ -var mergeWith = createAssigner(function(object, source, customizer) { - baseMerge(object, source, customizer); +var mergeWith = createAssigner(function(object, source, srcIndex, customizer) { + baseMerge(object, source, srcIndex, customizer); }); module.exports = mergeWith; diff --git a/lodash.mergewith/package.json b/lodash.mergewith/package.json index e898b99dd..3db4ee574 100644 --- a/lodash.mergewith/package.json +++ b/lodash.mergewith/package.json @@ -1,6 +1,6 @@ { "name": "lodash.mergewith", - "version": "4.0.1", + "version": "4.0.2", "description": "The lodash method `_.mergeWith` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", diff --git a/lodash.method/README.md b/lodash.method/README.md index cdadcaf2d..2a8089d39 100644 --- a/lodash.method/README.md +++ b/lodash.method/README.md @@ -1,4 +1,4 @@ -# lodash.method v4.0.1 +# lodash.method v4.0.2 The [lodash](https://lodash.com/) method `_.method` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var method = require('lodash.method'); ``` -See the [documentation](https://lodash.com/docs#method) or [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash.method) for more details. +See the [documentation](https://lodash.com/docs#method) or [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash.method) for more details. diff --git a/lodash.method/index.js b/lodash.method/index.js index ea0df65f6..c38c58325 100644 --- a/lodash.method/index.js +++ b/lodash.method/index.js @@ -1,5 +1,5 @@ /** - * lodash 4.0.1 (Custom Build) + * lodash 4.0.2 (Custom Build) * Build: `lodash modularize exports="npm" -o ./` * Copyright 2012-2016 The Dojo Foundation * Based on Underscore.js 1.8.3 @@ -24,6 +24,38 @@ var reIsDeepProp = /\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/, /** Used to match backslashes in property paths. */ var reEscapeChar = /\\(\\)?/g; +/** Used to determine if values are of the language type `Object`. */ +var objectTypes = { + 'function': true, + 'object': true +}; + +/** Detect free variable `exports`. */ +var freeExports = (objectTypes[typeof exports] && exports && !exports.nodeType) ? exports : null; + +/** Detect free variable `module`. */ +var freeModule = (objectTypes[typeof module] && module && !module.nodeType) ? module : null; + +/** Detect free variable `global` from Node.js. */ +var freeGlobal = checkGlobal(freeExports && freeModule && typeof global == 'object' && global); + +/** Detect free variable `self`. */ +var freeSelf = checkGlobal(objectTypes[typeof self] && self); + +/** Detect free variable `window`. */ +var freeWindow = checkGlobal(objectTypes[typeof window] && window); + +/** Detect `this` as the global object. */ +var thisGlobal = checkGlobal(objectTypes[typeof this] && this); + +/** + * Used as a reference to the global object. + * + * The `this` value is used if it's the global object to avoid Greasemonkey's + * restricted `window` object, otherwise the `window` object is used. + */ +var root = freeGlobal || ((freeWindow !== (thisGlobal && thisGlobal.window)) && freeWindow) || freeSelf || thisGlobal || Function('return this')(); + /** * A faster alternative to `Function#apply`, this function invokes `func` * with the `this` binding of `thisArg` and the arguments of `args`. @@ -31,11 +63,11 @@ var reEscapeChar = /\\(\\)?/g; * @private * @param {Function} func The function to invoke. * @param {*} thisArg The `this` binding of `func`. - * @param {...*} [args] The arguments to invoke `func` with. + * @param {...*} args The arguments to invoke `func` with. * @returns {*} Returns the result of `func`. */ function apply(func, thisArg, args) { - var length = args ? args.length : 0; + var length = args.length; switch (length) { case 0: return func.call(thisArg); case 1: return func.call(thisArg, args[0]); @@ -45,8 +77,19 @@ function apply(func, thisArg, args) { return func.apply(thisArg, args); } +/** + * Checks if `value` is a global object. + * + * @private + * @param {*} value The value to check. + * @returns {null|Object} Returns `value` if it's a global object, else `null`. + */ +function checkGlobal(value) { + return (value && value.Object === Object) ? value : null; +} + /** Used for built-in method references. */ -var objectProto = global.Object.prototype; +var objectProto = Object.prototype; /** * Used to resolve the [`toStringTag`](http://ecma-international.org/ecma-262/6.0/#sec-object.prototype.tostring) @@ -55,7 +98,7 @@ var objectProto = global.Object.prototype; var objectToString = objectProto.toString; /** Built-in value references. */ -var Symbol = global.Symbol; +var Symbol = root.Symbol; /** Used to convert symbols to primitives and strings. */ var symbolProto = Symbol ? Symbol.prototype : undefined, diff --git a/lodash.method/package.json b/lodash.method/package.json index 179f3d9d1..440024842 100644 --- a/lodash.method/package.json +++ b/lodash.method/package.json @@ -1,11 +1,11 @@ { "name": "lodash.method", - "version": "4.0.1", + "version": "4.0.2", "description": "The lodash method `_.method` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", "license": "MIT", - "keywords": "lodash, lodash-modularized, stdlib, util, method", + "keywords": "lodash-modularized, method", "author": "John-David Dalton (http://allyoucanleet.com/)", "contributors": [ "John-David Dalton (http://allyoucanleet.com/)", diff --git a/lodash.methodof/README.md b/lodash.methodof/README.md index 912cc39c3..9f4838667 100644 --- a/lodash.methodof/README.md +++ b/lodash.methodof/README.md @@ -1,4 +1,4 @@ -# lodash.methodof v4.0.1 +# lodash.methodof v4.0.2 The [lodash](https://lodash.com/) method `_.methodOf` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var methodOf = require('lodash.methodof'); ``` -See the [documentation](https://lodash.com/docs#methodOf) or [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash.methodof) for more details. +See the [documentation](https://lodash.com/docs#methodOf) or [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash.methodof) for more details. diff --git a/lodash.methodof/index.js b/lodash.methodof/index.js index 3b001cf4b..caf605de2 100644 --- a/lodash.methodof/index.js +++ b/lodash.methodof/index.js @@ -1,5 +1,5 @@ /** - * lodash 4.0.1 (Custom Build) + * lodash 4.0.2 (Custom Build) * Build: `lodash modularize exports="npm" -o ./` * Copyright 2012-2016 The Dojo Foundation * Based on Underscore.js 1.8.3 @@ -24,6 +24,38 @@ var reIsDeepProp = /\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/, /** Used to match backslashes in property paths. */ var reEscapeChar = /\\(\\)?/g; +/** Used to determine if values are of the language type `Object`. */ +var objectTypes = { + 'function': true, + 'object': true +}; + +/** Detect free variable `exports`. */ +var freeExports = (objectTypes[typeof exports] && exports && !exports.nodeType) ? exports : null; + +/** Detect free variable `module`. */ +var freeModule = (objectTypes[typeof module] && module && !module.nodeType) ? module : null; + +/** Detect free variable `global` from Node.js. */ +var freeGlobal = checkGlobal(freeExports && freeModule && typeof global == 'object' && global); + +/** Detect free variable `self`. */ +var freeSelf = checkGlobal(objectTypes[typeof self] && self); + +/** Detect free variable `window`. */ +var freeWindow = checkGlobal(objectTypes[typeof window] && window); + +/** Detect `this` as the global object. */ +var thisGlobal = checkGlobal(objectTypes[typeof this] && this); + +/** + * Used as a reference to the global object. + * + * The `this` value is used if it's the global object to avoid Greasemonkey's + * restricted `window` object, otherwise the `window` object is used. + */ +var root = freeGlobal || ((freeWindow !== (thisGlobal && thisGlobal.window)) && freeWindow) || freeSelf || thisGlobal || Function('return this')(); + /** * A faster alternative to `Function#apply`, this function invokes `func` * with the `this` binding of `thisArg` and the arguments of `args`. @@ -31,11 +63,11 @@ var reEscapeChar = /\\(\\)?/g; * @private * @param {Function} func The function to invoke. * @param {*} thisArg The `this` binding of `func`. - * @param {...*} [args] The arguments to invoke `func` with. + * @param {...*} args The arguments to invoke `func` with. * @returns {*} Returns the result of `func`. */ function apply(func, thisArg, args) { - var length = args ? args.length : 0; + var length = args.length; switch (length) { case 0: return func.call(thisArg); case 1: return func.call(thisArg, args[0]); @@ -45,8 +77,19 @@ function apply(func, thisArg, args) { return func.apply(thisArg, args); } +/** + * Checks if `value` is a global object. + * + * @private + * @param {*} value The value to check. + * @returns {null|Object} Returns `value` if it's a global object, else `null`. + */ +function checkGlobal(value) { + return (value && value.Object === Object) ? value : null; +} + /** Used for built-in method references. */ -var objectProto = global.Object.prototype; +var objectProto = Object.prototype; /** * Used to resolve the [`toStringTag`](http://ecma-international.org/ecma-262/6.0/#sec-object.prototype.tostring) @@ -55,7 +98,7 @@ var objectProto = global.Object.prototype; var objectToString = objectProto.toString; /** Built-in value references. */ -var Symbol = global.Symbol; +var Symbol = root.Symbol; /** Used to convert symbols to primitives and strings. */ var symbolProto = Symbol ? Symbol.prototype : undefined, diff --git a/lodash.methodof/package.json b/lodash.methodof/package.json index f074ae1a3..75ff7efca 100644 --- a/lodash.methodof/package.json +++ b/lodash.methodof/package.json @@ -1,11 +1,11 @@ { "name": "lodash.methodof", - "version": "4.0.1", + "version": "4.0.2", "description": "The lodash method `_.methodOf` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", "license": "MIT", - "keywords": "lodash, lodash-modularized, stdlib, util, methodof", + "keywords": "lodash-modularized, methodof", "author": "John-David Dalton (http://allyoucanleet.com/)", "contributors": [ "John-David Dalton (http://allyoucanleet.com/)", diff --git a/lodash.minby/README.md b/lodash.minby/README.md index 7dbd1bbde..a6baac3e9 100644 --- a/lodash.minby/README.md +++ b/lodash.minby/README.md @@ -1,4 +1,4 @@ -# lodash.minby v4.0.1 +# lodash.minby v4.0.2 The [lodash](https://lodash.com/) method `_.minBy` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var minBy = require('lodash.minby'); ``` -See the [documentation](https://lodash.com/docs#minBy) or [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash.minby) for more details. +See the [documentation](https://lodash.com/docs#minBy) or [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash.minby) for more details. diff --git a/lodash.minby/index.js b/lodash.minby/index.js index 8369e37c9..a2efdd14b 100644 --- a/lodash.minby/index.js +++ b/lodash.minby/index.js @@ -1,5 +1,5 @@ /** - * lodash 4.0.1 (Custom Build) + * lodash 4.0.2 (Custom Build) * Build: `lodash modularize exports="npm" -o ./` * Copyright 2012-2016 The Dojo Foundation * Based on Underscore.js 1.8.3 @@ -30,6 +30,38 @@ var reIsDeepProp = /\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/, /** Used to match backslashes in property paths. */ var reEscapeChar = /\\(\\)?/g; +/** Used to determine if values are of the language type `Object`. */ +var objectTypes = { + 'function': true, + 'object': true +}; + +/** Detect free variable `exports`. */ +var freeExports = (objectTypes[typeof exports] && exports && !exports.nodeType) ? exports : null; + +/** Detect free variable `module`. */ +var freeModule = (objectTypes[typeof module] && module && !module.nodeType) ? module : null; + +/** Detect free variable `global` from Node.js. */ +var freeGlobal = checkGlobal(freeExports && freeModule && typeof global == 'object' && global); + +/** Detect free variable `self`. */ +var freeSelf = checkGlobal(objectTypes[typeof self] && self); + +/** Detect free variable `window`. */ +var freeWindow = checkGlobal(objectTypes[typeof window] && window); + +/** Detect `this` as the global object. */ +var thisGlobal = checkGlobal(objectTypes[typeof this] && this); + +/** + * Used as a reference to the global object. + * + * The `this` value is used if it's the global object to avoid Greasemonkey's + * restricted `window` object, otherwise the `window` object is used. + */ +var root = freeGlobal || ((freeWindow !== (thisGlobal && thisGlobal.window)) && freeWindow) || freeSelf || thisGlobal || Function('return this')(); + /** * The base implementation of methods like `_.max` and `_.min` which accepts a * `comparator` to determine the extremum value. @@ -59,8 +91,19 @@ function baseExtremum(array, iteratee, comparator) { return result; } +/** + * Checks if `value` is a global object. + * + * @private + * @param {*} value The value to check. + * @returns {null|Object} Returns `value` if it's a global object, else `null`. + */ +function checkGlobal(value) { + return (value && value.Object === Object) ? value : null; +} + /** Used for built-in method references. */ -var objectProto = global.Object.prototype; +var objectProto = Object.prototype; /** * Used to resolve the [`toStringTag`](http://ecma-international.org/ecma-262/6.0/#sec-object.prototype.tostring) @@ -69,7 +112,7 @@ var objectProto = global.Object.prototype; var objectToString = objectProto.toString; /** Built-in value references. */ -var Symbol = global.Symbol; +var Symbol = root.Symbol; /** Used to convert symbols to primitives and strings. */ var symbolProto = Symbol ? Symbol.prototype : undefined, @@ -482,7 +525,7 @@ function property(path) { * _.minBy(objects, function(o) { return o.n; }); * // => { 'n': 1 } * - * // using the `_.property` iteratee shorthand + * // The `_.property` iteratee shorthand. * _.minBy(objects, 'n'); * // => { 'n': 1 } */ diff --git a/lodash.minby/package.json b/lodash.minby/package.json index ee0af995d..edf389599 100644 --- a/lodash.minby/package.json +++ b/lodash.minby/package.json @@ -1,11 +1,11 @@ { "name": "lodash.minby", - "version": "4.0.1", + "version": "4.0.2", "description": "The lodash method `_.minBy` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", "license": "MIT", - "keywords": "lodash, lodash-modularized, stdlib, util, minby", + "keywords": "lodash-modularized, minby", "author": "John-David Dalton (http://allyoucanleet.com/)", "contributors": [ "John-David Dalton (http://allyoucanleet.com/)", diff --git a/lodash.now/README.md b/lodash.now/README.md index d6c8b2f73..8e0d37a53 100644 --- a/lodash.now/README.md +++ b/lodash.now/README.md @@ -1,4 +1,4 @@ -# lodash.now v4.0.1 +# lodash.now v4.0.2 The [lodash](https://lodash.com/) method `_.now` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var now = require('lodash.now'); ``` -See the [documentation](https://lodash.com/docs#now) or [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash.now) for more details. +See the [documentation](https://lodash.com/docs#now) or [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash.now) for more details. diff --git a/lodash.now/index.js b/lodash.now/index.js index 8c9e1088e..d47329cf8 100644 --- a/lodash.now/index.js +++ b/lodash.now/index.js @@ -7,6 +7,15 @@ * Copyright Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors */ +/** Detect free variable `global` from Node.js. */ +var freeGlobal = typeof global == 'object' && global && global.Object === Object && global; + +/** Detect free variable `self`. */ +var freeSelf = typeof self == 'object' && self && self.Object === Object && self; + +/** Used as a reference to the global object. */ +var root = freeGlobal || freeSelf || Function('return this')(); + /** * Gets the timestamp of the number of milliseconds that have elapsed since * the Unix epoch (1 January 1970 00:00:00 UTC). @@ -23,8 +32,8 @@ * }, _.now()); * // => Logs the number of milliseconds it took for the deferred invocation. */ -function now() { - return Date.now(); -} +var now = function() { + return root.Date.now(); +}; module.exports = now; diff --git a/lodash.now/package.json b/lodash.now/package.json index 1551392aa..1fb8bcd91 100644 --- a/lodash.now/package.json +++ b/lodash.now/package.json @@ -1,6 +1,6 @@ { "name": "lodash.now", - "version": "4.0.1", + "version": "4.0.2", "description": "The lodash method `_.now` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", diff --git a/lodash.ntharg/LICENSE b/lodash.ntharg/LICENSE index b054ca5a3..e0c69d560 100644 --- a/lodash.ntharg/LICENSE +++ b/lodash.ntharg/LICENSE @@ -1,7 +1,17 @@ -Copyright 2012-2016 The Dojo Foundation -Based on Underscore.js, copyright 2009-2016 Jeremy Ashkenas, +Copyright jQuery Foundation and other contributors + +Based on Underscore.js, copyright Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors +This software consists of voluntary contributions made by many +individuals. For exact contribution history, see the revision history +available at https://github.com/lodash/lodash + +The following license applies to all parts of this software except as +documented below: + +==== + Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including @@ -20,3 +30,18 @@ NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + +==== + +Copyright and related rights for sample code are waived via CC0. Sample +code is defined as all source code displayed within the prose of the +documentation. + +CC0: http://creativecommons.org/publicdomain/zero/1.0/ + +==== + +Files located in the node_modules and vendor directories are externally +maintained libraries used by this software which have their own +licenses; we recommend you read them, as their terms may differ from the +terms above. diff --git a/lodash.ntharg/README.md b/lodash.ntharg/README.md index 285b364ad..4ef43d306 100644 --- a/lodash.ntharg/README.md +++ b/lodash.ntharg/README.md @@ -1,4 +1,4 @@ -# lodash.ntharg v4.0.1 +# lodash.ntharg v4.0.2 The [lodash](https://lodash.com/) method `_.nthArg` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var nthArg = require('lodash.ntharg'); ``` -See the [documentation](https://lodash.com/docs#nthArg) or [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash.ntharg) for more details. +See the [documentation](https://lodash.com/docs#nthArg) or [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash.ntharg) for more details. diff --git a/lodash.ntharg/index.js b/lodash.ntharg/index.js index 8a71babd0..2bfdea913 100644 --- a/lodash.ntharg/index.js +++ b/lodash.ntharg/index.js @@ -1,10 +1,10 @@ /** - * lodash 4.0.1 (Custom Build) + * lodash 4.0.2 (Custom Build) * Build: `lodash modularize exports="npm" -o ./` - * Copyright 2012-2016 The Dojo Foundation + * Copyright jQuery Foundation and other contributors + * Released under MIT license * Based on Underscore.js 1.8.3 - * Copyright 2009-2016 Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors - * Available under MIT license + * Copyright Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors */ /** Used as references for various `Number` constants. */ @@ -14,7 +14,8 @@ var INFINITY = 1 / 0, /** `Object#toString` result references. */ var funcTag = '[object Function]', - genTag = '[object GeneratorFunction]'; + genTag = '[object GeneratorFunction]', + symbolTag = '[object Symbol]'; /** Used to match leading and trailing whitespace. */ var reTrim = /^\s+|\s+$/g; @@ -35,7 +36,8 @@ var freeParseInt = parseInt; var objectProto = Object.prototype; /** - * Used to resolve the [`toStringTag`](http://ecma-international.org/ecma-262/6.0/#sec-object.prototype.tostring) + * Used to resolve the + * [`toStringTag`](http://ecma-international.org/ecma-262/6.0/#sec-object.prototype.tostring) * of values. */ var objectToString = objectProto.toString; @@ -45,9 +47,11 @@ var objectToString = objectProto.toString; * * @static * @memberOf _ + * @since 0.1.0 * @category Lang * @param {*} value The value to check. - * @returns {boolean} Returns `true` if `value` is correctly classified, else `false`. + * @returns {boolean} Returns `true` if `value` is correctly classified, + * else `false`. * @example * * _.isFunction(_); @@ -65,11 +69,13 @@ function isFunction(value) { } /** - * Checks if `value` is the [language type](https://es5.github.io/#x8) of `Object`. - * (e.g. arrays, functions, objects, regexes, `new Number(0)`, and `new String('')`) + * Checks if `value` is the + * [language type](http://www.ecma-international.org/ecma-262/6.0/#sec-ecmascript-language-types) + * of `Object`. (e.g. arrays, functions, objects, regexes, `new Number(0)`, and `new String('')`) * * @static * @memberOf _ + * @since 0.1.0 * @category Lang * @param {*} value The value to check. * @returns {boolean} Returns `true` if `value` is an object, else `false`. @@ -93,12 +99,65 @@ function isObject(value) { } /** - * Converts `value` to an integer. - * - * **Note:** This function is loosely based on [`ToInteger`](http://www.ecma-international.org/ecma-262/6.0/#sec-tointeger). + * Checks if `value` is object-like. A value is object-like if it's not `null` + * and has a `typeof` result of "object". * * @static * @memberOf _ + * @since 4.0.0 + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is object-like, else `false`. + * @example + * + * _.isObjectLike({}); + * // => true + * + * _.isObjectLike([1, 2, 3]); + * // => true + * + * _.isObjectLike(_.noop); + * // => false + * + * _.isObjectLike(null); + * // => false + */ +function isObjectLike(value) { + return !!value && typeof value == 'object'; +} + +/** + * Checks if `value` is classified as a `Symbol` primitive or object. + * + * @static + * @memberOf _ + * @since 4.0.0 + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is correctly classified, + * else `false`. + * @example + * + * _.isSymbol(Symbol.iterator); + * // => true + * + * _.isSymbol('abc'); + * // => false + */ +function isSymbol(value) { + return typeof value == 'symbol' || + (isObjectLike(value) && objectToString.call(value) == symbolTag); +} + +/** + * Converts `value` to an integer. + * + * **Note:** This function is loosely based on + * [`ToInteger`](http://www.ecma-international.org/ecma-262/6.0/#sec-tointeger). + * + * @static + * @memberOf _ + * @since 4.0.0 * @category Lang * @param {*} value The value to convert. * @returns {number} Returns the converted integer. @@ -134,6 +193,7 @@ function toInteger(value) { * * @static * @memberOf _ + * @since 4.0.0 * @category Lang * @param {*} value The value to process. * @returns {number} Returns the number. @@ -152,6 +212,12 @@ function toInteger(value) { * // => 3 */ function toNumber(value) { + if (typeof value == 'number') { + return value; + } + if (isSymbol(value)) { + return NAN; + } if (isObject(value)) { var other = isFunction(value.valueOf) ? value.valueOf() : value; value = isObject(other) ? (other + '') : other; @@ -171,6 +237,7 @@ function toNumber(value) { * * @static * @memberOf _ + * @since 4.0.0 * @category Util * @param {number} [n=0] The index of the argument to return. * @returns {Function} Returns the new function. diff --git a/lodash.ntharg/package.json b/lodash.ntharg/package.json index a59ffb9bf..5754af462 100644 --- a/lodash.ntharg/package.json +++ b/lodash.ntharg/package.json @@ -1,6 +1,6 @@ { "name": "lodash.ntharg", - "version": "4.0.1", + "version": "4.0.2", "description": "The lodash method `_.nthArg` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", @@ -9,7 +9,7 @@ "author": "John-David Dalton (http://allyoucanleet.com/)", "contributors": [ "John-David Dalton (http://allyoucanleet.com/)", - "Blaine Bublitz (https://github.com/phated)", + "Blaine Bublitz (https://github.com/phated)", "Mathias Bynens (https://mathiasbynens.be/)" ], "repository": "lodash/lodash", diff --git a/lodash.omit/README.md b/lodash.omit/README.md index 16d201cfc..3d6821fd6 100644 --- a/lodash.omit/README.md +++ b/lodash.omit/README.md @@ -1,4 +1,4 @@ -# lodash.omit v4.0.1 +# lodash.omit v4.0.2 The [lodash](https://lodash.com/) method `_.omit` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var omit = require('lodash.omit'); ``` -See the [documentation](https://lodash.com/docs#omit) or [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash.omit) for more details. +See the [documentation](https://lodash.com/docs#omit) or [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash.omit) for more details. diff --git a/lodash.omit/index.js b/lodash.omit/index.js index c6b9f3338..e79cf6a75 100644 --- a/lodash.omit/index.js +++ b/lodash.omit/index.js @@ -1,5 +1,5 @@ /** - * lodash 4.0.0 (Custom Build) + * lodash 4.0.2 (Custom Build) * Build: `lodash modularize exports="npm" -o ./` * Copyright 2012-2016 The Dojo Foundation * Based on Underscore.js 1.8.3 @@ -26,14 +26,14 @@ var LARGE_ARRAY_SIZE = 200; * @param {Array} array The array to iterate over. * @param {Function} iteratee The function invoked per iteration. * @param {*} [accumulator] The initial value. - * @param {boolean} [initFromArray] Specify using the first element of `array` as the initial value. + * @param {boolean} [initAccum] Specify using the first element of `array` as the initial value. * @returns {*} Returns the accumulated value. */ -function arrayReduce(array, iteratee, accumulator, initFromArray) { +function arrayReduce(array, iteratee, accumulator, initAccum) { var index = -1, length = array.length; - if (initFromArray && length) { + if (initAccum && length) { accumulator = array[++index]; } while (++index < length) { diff --git a/lodash.omit/package.json b/lodash.omit/package.json index 5cc2084ed..3921cb98f 100644 --- a/lodash.omit/package.json +++ b/lodash.omit/package.json @@ -1,6 +1,6 @@ { "name": "lodash.omit", - "version": "4.0.1", + "version": "4.0.2", "description": "The lodash method `_.omit` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", diff --git a/lodash.omitby/README.md b/lodash.omitby/README.md index 5c75883c7..db8ca9256 100644 --- a/lodash.omitby/README.md +++ b/lodash.omitby/README.md @@ -1,4 +1,4 @@ -# lodash.omitby v4.0.1 +# lodash.omitby v4.0.2 The [lodash](https://lodash.com/) method `_.omitBy` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var omitBy = require('lodash.omitby'); ``` -See the [documentation](https://lodash.com/docs#omitBy) or [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash.omitby) for more details. +See the [documentation](https://lodash.com/docs#omitBy) or [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash.omitby) for more details. diff --git a/lodash.omitby/index.js b/lodash.omitby/index.js index 275cc76e7..0230eb5f5 100644 --- a/lodash.omitby/index.js +++ b/lodash.omitby/index.js @@ -1,5 +1,5 @@ /** - * lodash 4.0.1 (Custom Build) + * lodash 4.0.2 (Custom Build) * Build: `lodash modularize exports="npm" -o ./` * Copyright 2012-2016 The Dojo Foundation * Based on Underscore.js 1.8.3 @@ -32,8 +32,51 @@ var reIsDeepProp = /\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/, /** Used to match backslashes in property paths. */ var reEscapeChar = /\\(\\)?/g; +/** Used to determine if values are of the language type `Object`. */ +var objectTypes = { + 'function': true, + 'object': true +}; + +/** Detect free variable `exports`. */ +var freeExports = (objectTypes[typeof exports] && exports && !exports.nodeType) ? exports : null; + +/** Detect free variable `module`. */ +var freeModule = (objectTypes[typeof module] && module && !module.nodeType) ? module : null; + +/** Detect free variable `global` from Node.js. */ +var freeGlobal = checkGlobal(freeExports && freeModule && typeof global == 'object' && global); + +/** Detect free variable `self`. */ +var freeSelf = checkGlobal(objectTypes[typeof self] && self); + +/** Detect free variable `window`. */ +var freeWindow = checkGlobal(objectTypes[typeof window] && window); + +/** Detect `this` as the global object. */ +var thisGlobal = checkGlobal(objectTypes[typeof this] && this); + +/** + * Used as a reference to the global object. + * + * The `this` value is used if it's the global object to avoid Greasemonkey's + * restricted `window` object, otherwise the `window` object is used. + */ +var root = freeGlobal || ((freeWindow !== (thisGlobal && thisGlobal.window)) && freeWindow) || freeSelf || thisGlobal || Function('return this')(); + +/** + * Checks if `value` is a global object. + * + * @private + * @param {*} value The value to check. + * @returns {null|Object} Returns `value` if it's a global object, else `null`. + */ +function checkGlobal(value) { + return (value && value.Object === Object) ? value : null; +} + /** Used for built-in method references. */ -var objectProto = global.Object.prototype; +var objectProto = Object.prototype; /** * Used to resolve the [`toStringTag`](http://ecma-international.org/ecma-262/6.0/#sec-object.prototype.tostring) @@ -42,7 +85,7 @@ var objectProto = global.Object.prototype; var objectToString = objectProto.toString; /** Built-in value references. */ -var Symbol = global.Symbol; +var Symbol = root.Symbol; /** Used to convert symbols to primitives and strings. */ var symbolProto = Symbol ? Symbol.prototype : undefined, diff --git a/lodash.omitby/package.json b/lodash.omitby/package.json index a4407f0ee..63fdbdb96 100644 --- a/lodash.omitby/package.json +++ b/lodash.omitby/package.json @@ -1,11 +1,11 @@ { "name": "lodash.omitby", - "version": "4.0.1", + "version": "4.0.2", "description": "The lodash method `_.omitBy` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", "license": "MIT", - "keywords": "lodash, lodash-modularized, stdlib, util, omitby", + "keywords": "lodash-modularized, omitby", "author": "John-David Dalton (http://allyoucanleet.com/)", "contributors": [ "John-David Dalton (http://allyoucanleet.com/)", diff --git a/lodash.orderby/README.md b/lodash.orderby/README.md index e9c2c2333..1c5b9722d 100644 --- a/lodash.orderby/README.md +++ b/lodash.orderby/README.md @@ -1,4 +1,4 @@ -# lodash.orderby v4.0.1 +# lodash.orderby v4.0.2 The [lodash](https://lodash.com/) method `_.orderBy` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var orderBy = require('lodash.orderby'); ``` -See the [documentation](https://lodash.com/docs#orderBy) or [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash.orderby) for more details. +See the [documentation](https://lodash.com/docs#orderBy) or [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash.orderby) for more details. diff --git a/lodash.orderby/index.js b/lodash.orderby/index.js index 988c60000..d9d0ef8ff 100644 --- a/lodash.orderby/index.js +++ b/lodash.orderby/index.js @@ -1,5 +1,5 @@ /** - * lodash 4.0.1 (Custom Build) + * lodash 4.0.2 (Custom Build) * Build: `lodash modularize exports="npm" -o ./` * Copyright 2012-2016 The Dojo Foundation * Based on Underscore.js 1.8.3 @@ -35,6 +35,38 @@ var reIsDeepProp = /\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/, /** Used to match backslashes in property paths. */ var reEscapeChar = /\\(\\)?/g; +/** Used to determine if values are of the language type `Object`. */ +var objectTypes = { + 'function': true, + 'object': true +}; + +/** Detect free variable `exports`. */ +var freeExports = (objectTypes[typeof exports] && exports && !exports.nodeType) ? exports : null; + +/** Detect free variable `module`. */ +var freeModule = (objectTypes[typeof module] && module && !module.nodeType) ? module : null; + +/** Detect free variable `global` from Node.js. */ +var freeGlobal = checkGlobal(freeExports && freeModule && typeof global == 'object' && global); + +/** Detect free variable `self`. */ +var freeSelf = checkGlobal(objectTypes[typeof self] && self); + +/** Detect free variable `window`. */ +var freeWindow = checkGlobal(objectTypes[typeof window] && window); + +/** Detect `this` as the global object. */ +var thisGlobal = checkGlobal(objectTypes[typeof this] && this); + +/** + * Used as a reference to the global object. + * + * The `this` value is used if it's the global object to avoid Greasemonkey's + * restricted `window` object, otherwise the `window` object is used. + */ +var root = freeGlobal || ((freeWindow !== (thisGlobal && thisGlobal.window)) && freeWindow) || freeSelf || thisGlobal || Function('return this')(); + /** * The base implementation of `_.sortBy` which uses `comparer` to define * the sort order of `array` and replaces criteria objects with their @@ -55,6 +87,17 @@ function baseSortBy(array, comparer) { return array; } +/** + * Checks if `value` is a global object. + * + * @private + * @param {*} value The value to check. + * @returns {null|Object} Returns `value` if it's a global object, else `null`. + */ +function checkGlobal(value) { + return (value && value.Object === Object) ? value : null; +} + /** * Compares values to sort them in ascending order. * @@ -129,7 +172,7 @@ function compareMultiple(object, other, orders) { } /** Used for built-in method references. */ -var objectProto = global.Object.prototype; +var objectProto = Object.prototype; /** * Used to resolve the [`toStringTag`](http://ecma-international.org/ecma-262/6.0/#sec-object.prototype.tostring) @@ -138,7 +181,7 @@ var objectProto = global.Object.prototype; var objectToString = objectProto.toString; /** Built-in value references. */ -var Symbol = global.Symbol; +var Symbol = root.Symbol; /** Used to convert symbols to primitives and strings. */ var symbolProto = Symbol ? Symbol.prototype : undefined, @@ -411,7 +454,7 @@ function stringToPath(string) { * { 'user': 'barney', 'age': 36 } * ]; * - * // sort by `user` in ascending order and by `age` in descending order + * // Sort by `user` in ascending order and by `age` in descending order. * _.orderBy(users, ['user', 'age'], ['asc', 'desc']); * // => objects for [['barney', 36], ['barney', 34], ['fred', 48], ['fred', 42]] */ diff --git a/lodash.orderby/package.json b/lodash.orderby/package.json index 02b18b6ad..1d1065c87 100644 --- a/lodash.orderby/package.json +++ b/lodash.orderby/package.json @@ -1,11 +1,11 @@ { "name": "lodash.orderby", - "version": "4.0.1", + "version": "4.0.2", "description": "The lodash method `_.orderBy` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", "license": "MIT", - "keywords": "lodash, lodash-modularized, stdlib, util, orderby", + "keywords": "lodash-modularized, orderby", "author": "John-David Dalton (http://allyoucanleet.com/)", "contributors": [ "John-David Dalton (http://allyoucanleet.com/)", diff --git a/lodash.over/README.md b/lodash.over/README.md index 2663902f9..104249838 100644 --- a/lodash.over/README.md +++ b/lodash.over/README.md @@ -1,4 +1,4 @@ -# lodash.over v4.0.1 +# lodash.over v4.0.2 The [lodash](https://lodash.com/) method `_.over` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var over = require('lodash.over'); ``` -See the [documentation](https://lodash.com/docs#over) or [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash.over) for more details. +See the [documentation](https://lodash.com/docs#over) or [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash.over) for more details. diff --git a/lodash.over/index.js b/lodash.over/index.js index cf9e21fb3..6586319fc 100644 --- a/lodash.over/index.js +++ b/lodash.over/index.js @@ -1,5 +1,5 @@ /** - * lodash 4.0.1 (Custom Build) + * lodash 4.0.2 (Custom Build) * Build: `lodash modularize exports="npm" -o ./` * Copyright 2012-2016 The Dojo Foundation * Based on Underscore.js 1.8.3 @@ -33,6 +33,38 @@ var reIsDeepProp = /\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/, /** Used to match backslashes in property paths. */ var reEscapeChar = /\\(\\)?/g; +/** Used to determine if values are of the language type `Object`. */ +var objectTypes = { + 'function': true, + 'object': true +}; + +/** Detect free variable `exports`. */ +var freeExports = (objectTypes[typeof exports] && exports && !exports.nodeType) ? exports : null; + +/** Detect free variable `module`. */ +var freeModule = (objectTypes[typeof module] && module && !module.nodeType) ? module : null; + +/** Detect free variable `global` from Node.js. */ +var freeGlobal = checkGlobal(freeExports && freeModule && typeof global == 'object' && global); + +/** Detect free variable `self`. */ +var freeSelf = checkGlobal(objectTypes[typeof self] && self); + +/** Detect free variable `window`. */ +var freeWindow = checkGlobal(objectTypes[typeof window] && window); + +/** Detect `this` as the global object. */ +var thisGlobal = checkGlobal(objectTypes[typeof this] && this); + +/** + * Used as a reference to the global object. + * + * The `this` value is used if it's the global object to avoid Greasemonkey's + * restricted `window` object, otherwise the `window` object is used. + */ +var root = freeGlobal || ((freeWindow !== (thisGlobal && thisGlobal.window)) && freeWindow) || freeSelf || thisGlobal || Function('return this')(); + /** * A faster alternative to `Function#apply`, this function invokes `func` * with the `this` binding of `thisArg` and the arguments of `args`. @@ -40,11 +72,11 @@ var reEscapeChar = /\\(\\)?/g; * @private * @param {Function} func The function to invoke. * @param {*} thisArg The `this` binding of `func`. - * @param {...*} [args] The arguments to invoke `func` with. + * @param {...*} args The arguments to invoke `func` with. * @returns {*} Returns the result of `func`. */ function apply(func, thisArg, args) { - var length = args ? args.length : 0; + var length = args.length; switch (length) { case 0: return func.call(thisArg); case 1: return func.call(thisArg, args[0]); @@ -54,8 +86,19 @@ function apply(func, thisArg, args) { return func.apply(thisArg, args); } +/** + * Checks if `value` is a global object. + * + * @private + * @param {*} value The value to check. + * @returns {null|Object} Returns `value` if it's a global object, else `null`. + */ +function checkGlobal(value) { + return (value && value.Object === Object) ? value : null; +} + /** Used for built-in method references. */ -var objectProto = global.Object.prototype; +var objectProto = Object.prototype; /** * Used to resolve the [`toStringTag`](http://ecma-international.org/ecma-262/6.0/#sec-object.prototype.tostring) @@ -64,7 +107,7 @@ var objectProto = global.Object.prototype; var objectToString = objectProto.toString; /** Built-in value references. */ -var Symbol = global.Symbol; +var Symbol = root.Symbol; /** Used to convert symbols to primitives and strings. */ var symbolProto = Symbol ? Symbol.prototype : undefined, diff --git a/lodash.over/package.json b/lodash.over/package.json index 0f49d6ced..ec94f1818 100644 --- a/lodash.over/package.json +++ b/lodash.over/package.json @@ -1,11 +1,11 @@ { "name": "lodash.over", - "version": "4.0.1", + "version": "4.0.2", "description": "The lodash method `_.over` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", "license": "MIT", - "keywords": "lodash, lodash-modularized, stdlib, util, over", + "keywords": "lodash-modularized, over", "author": "John-David Dalton (http://allyoucanleet.com/)", "contributors": [ "John-David Dalton (http://allyoucanleet.com/)", diff --git a/lodash.overargs/README.md b/lodash.overargs/README.md index 66a3cbf64..3934ddbef 100644 --- a/lodash.overargs/README.md +++ b/lodash.overargs/README.md @@ -1,4 +1,4 @@ -# lodash.overargs v4.0.1 +# lodash.overargs v4.0.2 The [lodash](https://lodash.com/) method `_.overArgs` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var overArgs = require('lodash.overargs'); ``` -See the [documentation](https://lodash.com/docs#overArgs) or [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash.overargs) for more details. +See the [documentation](https://lodash.com/docs#overArgs) or [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash.overargs) for more details. diff --git a/lodash.overargs/index.js b/lodash.overargs/index.js index cbd49e8bd..ddd4e5ee5 100644 --- a/lodash.overargs/index.js +++ b/lodash.overargs/index.js @@ -1,5 +1,5 @@ /** - * lodash 4.0.1 (Custom Build) + * lodash 4.0.2 (Custom Build) * Build: `lodash modularize exports="npm" -o ./` * Copyright 2012-2016 The Dojo Foundation * Based on Underscore.js 1.8.3 @@ -33,6 +33,38 @@ var reIsDeepProp = /\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/, /** Used to match backslashes in property paths. */ var reEscapeChar = /\\(\\)?/g; +/** Used to determine if values are of the language type `Object`. */ +var objectTypes = { + 'function': true, + 'object': true +}; + +/** Detect free variable `exports`. */ +var freeExports = (objectTypes[typeof exports] && exports && !exports.nodeType) ? exports : null; + +/** Detect free variable `module`. */ +var freeModule = (objectTypes[typeof module] && module && !module.nodeType) ? module : null; + +/** Detect free variable `global` from Node.js. */ +var freeGlobal = checkGlobal(freeExports && freeModule && typeof global == 'object' && global); + +/** Detect free variable `self`. */ +var freeSelf = checkGlobal(objectTypes[typeof self] && self); + +/** Detect free variable `window`. */ +var freeWindow = checkGlobal(objectTypes[typeof window] && window); + +/** Detect `this` as the global object. */ +var thisGlobal = checkGlobal(objectTypes[typeof this] && this); + +/** + * Used as a reference to the global object. + * + * The `this` value is used if it's the global object to avoid Greasemonkey's + * restricted `window` object, otherwise the `window` object is used. + */ +var root = freeGlobal || ((freeWindow !== (thisGlobal && thisGlobal.window)) && freeWindow) || freeSelf || thisGlobal || Function('return this')(); + /** * A faster alternative to `Function#apply`, this function invokes `func` * with the `this` binding of `thisArg` and the arguments of `args`. @@ -40,11 +72,11 @@ var reEscapeChar = /\\(\\)?/g; * @private * @param {Function} func The function to invoke. * @param {*} thisArg The `this` binding of `func`. - * @param {...*} [args] The arguments to invoke `func` with. + * @param {...*} args The arguments to invoke `func` with. * @returns {*} Returns the result of `func`. */ function apply(func, thisArg, args) { - var length = args ? args.length : 0; + var length = args.length; switch (length) { case 0: return func.call(thisArg); case 1: return func.call(thisArg, args[0]); @@ -54,8 +86,19 @@ function apply(func, thisArg, args) { return func.apply(thisArg, args); } +/** + * Checks if `value` is a global object. + * + * @private + * @param {*} value The value to check. + * @returns {null|Object} Returns `value` if it's a global object, else `null`. + */ +function checkGlobal(value) { + return (value && value.Object === Object) ? value : null; +} + /** Used for built-in method references. */ -var objectProto = global.Object.prototype; +var objectProto = Object.prototype; /** * Used to resolve the [`toStringTag`](http://ecma-international.org/ecma-262/6.0/#sec-object.prototype.tostring) @@ -64,7 +107,7 @@ var objectProto = global.Object.prototype; var objectToString = objectProto.toString; /** Built-in value references. */ -var Symbol = global.Symbol; +var Symbol = root.Symbol; /* Built-in method references for those with the same name as other `lodash` methods. */ var nativeMin = Math.min; diff --git a/lodash.overargs/package.json b/lodash.overargs/package.json index 9042cf65c..6290cc0fa 100644 --- a/lodash.overargs/package.json +++ b/lodash.overargs/package.json @@ -1,11 +1,11 @@ { "name": "lodash.overargs", - "version": "4.0.1", + "version": "4.0.2", "description": "The lodash method `_.overArgs` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", "license": "MIT", - "keywords": "lodash, lodash-modularized, stdlib, util, overargs", + "keywords": "lodash-modularized, overargs", "author": "John-David Dalton (http://allyoucanleet.com/)", "contributors": [ "John-David Dalton (http://allyoucanleet.com/)", diff --git a/lodash.overevery/README.md b/lodash.overevery/README.md index fbeb1af1c..1822e62c8 100644 --- a/lodash.overevery/README.md +++ b/lodash.overevery/README.md @@ -1,4 +1,4 @@ -# lodash.overevery v4.0.1 +# lodash.overevery v4.0.2 The [lodash](https://lodash.com/) method `_.overEvery` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var overEvery = require('lodash.overevery'); ``` -See the [documentation](https://lodash.com/docs#overEvery) or [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash.overevery) for more details. +See the [documentation](https://lodash.com/docs#overEvery) or [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash.overevery) for more details. diff --git a/lodash.overevery/index.js b/lodash.overevery/index.js index 7a49c3fe1..c056a4fb2 100644 --- a/lodash.overevery/index.js +++ b/lodash.overevery/index.js @@ -1,5 +1,5 @@ /** - * lodash 4.0.1 (Custom Build) + * lodash 4.0.2 (Custom Build) * Build: `lodash modularize exports="npm" -o ./` * Copyright 2012-2016 The Dojo Foundation * Based on Underscore.js 1.8.3 @@ -33,6 +33,38 @@ var reIsDeepProp = /\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/, /** Used to match backslashes in property paths. */ var reEscapeChar = /\\(\\)?/g; +/** Used to determine if values are of the language type `Object`. */ +var objectTypes = { + 'function': true, + 'object': true +}; + +/** Detect free variable `exports`. */ +var freeExports = (objectTypes[typeof exports] && exports && !exports.nodeType) ? exports : null; + +/** Detect free variable `module`. */ +var freeModule = (objectTypes[typeof module] && module && !module.nodeType) ? module : null; + +/** Detect free variable `global` from Node.js. */ +var freeGlobal = checkGlobal(freeExports && freeModule && typeof global == 'object' && global); + +/** Detect free variable `self`. */ +var freeSelf = checkGlobal(objectTypes[typeof self] && self); + +/** Detect free variable `window`. */ +var freeWindow = checkGlobal(objectTypes[typeof window] && window); + +/** Detect `this` as the global object. */ +var thisGlobal = checkGlobal(objectTypes[typeof this] && this); + +/** + * Used as a reference to the global object. + * + * The `this` value is used if it's the global object to avoid Greasemonkey's + * restricted `window` object, otherwise the `window` object is used. + */ +var root = freeGlobal || ((freeWindow !== (thisGlobal && thisGlobal.window)) && freeWindow) || freeSelf || thisGlobal || Function('return this')(); + /** * A faster alternative to `Function#apply`, this function invokes `func` * with the `this` binding of `thisArg` and the arguments of `args`. @@ -40,11 +72,11 @@ var reEscapeChar = /\\(\\)?/g; * @private * @param {Function} func The function to invoke. * @param {*} thisArg The `this` binding of `func`. - * @param {...*} [args] The arguments to invoke `func` with. + * @param {...*} args The arguments to invoke `func` with. * @returns {*} Returns the result of `func`. */ function apply(func, thisArg, args) { - var length = args ? args.length : 0; + var length = args.length; switch (length) { case 0: return func.call(thisArg); case 1: return func.call(thisArg, args[0]); @@ -75,8 +107,19 @@ function arrayEvery(array, predicate) { return true; } +/** + * Checks if `value` is a global object. + * + * @private + * @param {*} value The value to check. + * @returns {null|Object} Returns `value` if it's a global object, else `null`. + */ +function checkGlobal(value) { + return (value && value.Object === Object) ? value : null; +} + /** Used for built-in method references. */ -var objectProto = global.Object.prototype; +var objectProto = Object.prototype; /** * Used to resolve the [`toStringTag`](http://ecma-international.org/ecma-262/6.0/#sec-object.prototype.tostring) @@ -85,7 +128,7 @@ var objectProto = global.Object.prototype; var objectToString = objectProto.toString; /** Built-in value references. */ -var Symbol = global.Symbol; +var Symbol = root.Symbol; /** Used to convert symbols to primitives and strings. */ var symbolProto = Symbol ? Symbol.prototype : undefined, diff --git a/lodash.overevery/package.json b/lodash.overevery/package.json index 13902ea0b..7f5fc8435 100644 --- a/lodash.overevery/package.json +++ b/lodash.overevery/package.json @@ -1,11 +1,11 @@ { "name": "lodash.overevery", - "version": "4.0.1", + "version": "4.0.2", "description": "The lodash method `_.overEvery` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", "license": "MIT", - "keywords": "lodash, lodash-modularized, stdlib, util, overevery", + "keywords": "lodash-modularized, overevery", "author": "John-David Dalton (http://allyoucanleet.com/)", "contributors": [ "John-David Dalton (http://allyoucanleet.com/)", diff --git a/lodash.oversome/README.md b/lodash.oversome/README.md index e19dc6a1f..63a780755 100644 --- a/lodash.oversome/README.md +++ b/lodash.oversome/README.md @@ -1,4 +1,4 @@ -# lodash.oversome v4.0.1 +# lodash.oversome v4.0.2 The [lodash](https://lodash.com/) method `_.overSome` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var overSome = require('lodash.oversome'); ``` -See the [documentation](https://lodash.com/docs#overSome) or [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash.oversome) for more details. +See the [documentation](https://lodash.com/docs#overSome) or [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash.oversome) for more details. diff --git a/lodash.oversome/index.js b/lodash.oversome/index.js index 829c15926..de61c800a 100644 --- a/lodash.oversome/index.js +++ b/lodash.oversome/index.js @@ -1,5 +1,5 @@ /** - * lodash 4.0.1 (Custom Build) + * lodash 4.0.2 (Custom Build) * Build: `lodash modularize exports="npm" -o ./` * Copyright 2012-2016 The Dojo Foundation * Based on Underscore.js 1.8.3 @@ -33,6 +33,38 @@ var reIsDeepProp = /\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/, /** Used to match backslashes in property paths. */ var reEscapeChar = /\\(\\)?/g; +/** Used to determine if values are of the language type `Object`. */ +var objectTypes = { + 'function': true, + 'object': true +}; + +/** Detect free variable `exports`. */ +var freeExports = (objectTypes[typeof exports] && exports && !exports.nodeType) ? exports : null; + +/** Detect free variable `module`. */ +var freeModule = (objectTypes[typeof module] && module && !module.nodeType) ? module : null; + +/** Detect free variable `global` from Node.js. */ +var freeGlobal = checkGlobal(freeExports && freeModule && typeof global == 'object' && global); + +/** Detect free variable `self`. */ +var freeSelf = checkGlobal(objectTypes[typeof self] && self); + +/** Detect free variable `window`. */ +var freeWindow = checkGlobal(objectTypes[typeof window] && window); + +/** Detect `this` as the global object. */ +var thisGlobal = checkGlobal(objectTypes[typeof this] && this); + +/** + * Used as a reference to the global object. + * + * The `this` value is used if it's the global object to avoid Greasemonkey's + * restricted `window` object, otherwise the `window` object is used. + */ +var root = freeGlobal || ((freeWindow !== (thisGlobal && thisGlobal.window)) && freeWindow) || freeSelf || thisGlobal || Function('return this')(); + /** * A faster alternative to `Function#apply`, this function invokes `func` * with the `this` binding of `thisArg` and the arguments of `args`. @@ -40,11 +72,11 @@ var reEscapeChar = /\\(\\)?/g; * @private * @param {Function} func The function to invoke. * @param {*} thisArg The `this` binding of `func`. - * @param {...*} [args] The arguments to invoke `func` with. + * @param {...*} args The arguments to invoke `func` with. * @returns {*} Returns the result of `func`. */ function apply(func, thisArg, args) { - var length = args ? args.length : 0; + var length = args.length; switch (length) { case 0: return func.call(thisArg); case 1: return func.call(thisArg, args[0]); @@ -75,8 +107,19 @@ function arraySome(array, predicate) { return false; } +/** + * Checks if `value` is a global object. + * + * @private + * @param {*} value The value to check. + * @returns {null|Object} Returns `value` if it's a global object, else `null`. + */ +function checkGlobal(value) { + return (value && value.Object === Object) ? value : null; +} + /** Used for built-in method references. */ -var objectProto = global.Object.prototype; +var objectProto = Object.prototype; /** * Used to resolve the [`toStringTag`](http://ecma-international.org/ecma-262/6.0/#sec-object.prototype.tostring) @@ -85,7 +128,7 @@ var objectProto = global.Object.prototype; var objectToString = objectProto.toString; /** Built-in value references. */ -var Symbol = global.Symbol; +var Symbol = root.Symbol; /** Used to convert symbols to primitives and strings. */ var symbolProto = Symbol ? Symbol.prototype : undefined, diff --git a/lodash.oversome/package.json b/lodash.oversome/package.json index 4be6ec49d..099e107a4 100644 --- a/lodash.oversome/package.json +++ b/lodash.oversome/package.json @@ -1,11 +1,11 @@ { "name": "lodash.oversome", - "version": "4.0.1", + "version": "4.0.2", "description": "The lodash method `_.overSome` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", "license": "MIT", - "keywords": "lodash, lodash-modularized, stdlib, util, oversome", + "keywords": "lodash-modularized, oversome", "author": "John-David Dalton (http://allyoucanleet.com/)", "contributors": [ "John-David Dalton (http://allyoucanleet.com/)", diff --git a/lodash.padend/README.md b/lodash.padend/README.md index 6056eb3ca..8a35aecc1 100644 --- a/lodash.padend/README.md +++ b/lodash.padend/README.md @@ -1,4 +1,4 @@ -# lodash.padend v4.0.1 +# lodash.padend v4.0.2 The [lodash](https://lodash.com/) method `_.padEnd` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var padEnd = require('lodash.padend'); ``` -See the [documentation](https://lodash.com/docs#padEnd) or [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash.padend) for more details. +See the [documentation](https://lodash.com/docs#padEnd) or [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash.padend) for more details. diff --git a/lodash.padend/index.js b/lodash.padend/index.js index 013c1fc12..f9f6f19e8 100644 --- a/lodash.padend/index.js +++ b/lodash.padend/index.js @@ -1,5 +1,5 @@ /** - * lodash 4.0.1 (Custom Build) + * lodash 4.0.2 (Custom Build) * Build: `lodash modularize exports="npm" -o ./` * Copyright 2012-2016 The Dojo Foundation * Based on Underscore.js 1.8.3 @@ -59,9 +59,52 @@ var reComplexSymbol = RegExp(rsFitz + '(?=' + rsFitz + ')|' + rsSymbol + rsSeq, /** Used to detect strings with [zero-width joiners or code points from the astral planes](http://eev.ee/blog/2015/09/12/dark-corners-of-unicode/). */ var reHasComplexSymbol = RegExp('[' + rsZWJ + rsAstralRange + rsComboMarksRange + rsComboSymbolsRange + rsVarRange + ']'); -/** Built-in method references without a dependency on `global`. */ +/** Used to determine if values are of the language type `Object`. */ +var objectTypes = { + 'function': true, + 'object': true +}; + +/** Built-in method references without a dependency on `root`. */ var freeParseInt = parseInt; +/** Detect free variable `exports`. */ +var freeExports = (objectTypes[typeof exports] && exports && !exports.nodeType) ? exports : null; + +/** Detect free variable `module`. */ +var freeModule = (objectTypes[typeof module] && module && !module.nodeType) ? module : null; + +/** Detect free variable `global` from Node.js. */ +var freeGlobal = checkGlobal(freeExports && freeModule && typeof global == 'object' && global); + +/** Detect free variable `self`. */ +var freeSelf = checkGlobal(objectTypes[typeof self] && self); + +/** Detect free variable `window`. */ +var freeWindow = checkGlobal(objectTypes[typeof window] && window); + +/** Detect `this` as the global object. */ +var thisGlobal = checkGlobal(objectTypes[typeof this] && this); + +/** + * Used as a reference to the global object. + * + * The `this` value is used if it's the global object to avoid Greasemonkey's + * restricted `window` object, otherwise the `window` object is used. + */ +var root = freeGlobal || ((freeWindow !== (thisGlobal && thisGlobal.window)) && freeWindow) || freeSelf || thisGlobal || Function('return this')(); + +/** + * Checks if `value` is a global object. + * + * @private + * @param {*} value The value to check. + * @returns {null|Object} Returns `value` if it's a global object, else `null`. + */ +function checkGlobal(value) { + return (value && value.Object === Object) ? value : null; +} + /** * Gets the number of symbols in `string`. * @@ -92,7 +135,7 @@ function stringToArray(string) { } /** Used for built-in method references. */ -var objectProto = global.Object.prototype; +var objectProto = Object.prototype; /** * Used to resolve the [`toStringTag`](http://ecma-international.org/ecma-262/6.0/#sec-object.prototype.tostring) @@ -101,7 +144,7 @@ var objectProto = global.Object.prototype; var objectToString = objectProto.toString; /** Built-in value references. */ -var Symbol = global.Symbol; +var Symbol = root.Symbol; /* Built-in method references for those with the same name as other `lodash` methods. */ var nativeCeil = Math.ceil; diff --git a/lodash.padend/package.json b/lodash.padend/package.json index cf40c217e..19522b386 100644 --- a/lodash.padend/package.json +++ b/lodash.padend/package.json @@ -1,11 +1,11 @@ { "name": "lodash.padend", - "version": "4.0.1", + "version": "4.0.2", "description": "The lodash method `_.padEnd` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", "license": "MIT", - "keywords": "lodash, lodash-modularized, stdlib, util, padend", + "keywords": "lodash-modularized, padend", "author": "John-David Dalton (http://allyoucanleet.com/)", "contributors": [ "John-David Dalton (http://allyoucanleet.com/)", diff --git a/lodash.padstart/README.md b/lodash.padstart/README.md index 9cc19a97e..7a80f460e 100644 --- a/lodash.padstart/README.md +++ b/lodash.padstart/README.md @@ -1,4 +1,4 @@ -# lodash.padstart v4.0.1 +# lodash.padstart v4.0.2 The [lodash](https://lodash.com/) method `_.padStart` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var padStart = require('lodash.padstart'); ``` -See the [documentation](https://lodash.com/docs#padStart) or [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash.padstart) for more details. +See the [documentation](https://lodash.com/docs#padStart) or [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash.padstart) for more details. diff --git a/lodash.padstart/index.js b/lodash.padstart/index.js index 5f2fb5c63..b22052a0b 100644 --- a/lodash.padstart/index.js +++ b/lodash.padstart/index.js @@ -1,5 +1,5 @@ /** - * lodash 4.0.1 (Custom Build) + * lodash 4.0.2 (Custom Build) * Build: `lodash modularize exports="npm" -o ./` * Copyright 2012-2016 The Dojo Foundation * Based on Underscore.js 1.8.3 @@ -59,9 +59,52 @@ var reComplexSymbol = RegExp(rsFitz + '(?=' + rsFitz + ')|' + rsSymbol + rsSeq, /** Used to detect strings with [zero-width joiners or code points from the astral planes](http://eev.ee/blog/2015/09/12/dark-corners-of-unicode/). */ var reHasComplexSymbol = RegExp('[' + rsZWJ + rsAstralRange + rsComboMarksRange + rsComboSymbolsRange + rsVarRange + ']'); -/** Built-in method references without a dependency on `global`. */ +/** Used to determine if values are of the language type `Object`. */ +var objectTypes = { + 'function': true, + 'object': true +}; + +/** Built-in method references without a dependency on `root`. */ var freeParseInt = parseInt; +/** Detect free variable `exports`. */ +var freeExports = (objectTypes[typeof exports] && exports && !exports.nodeType) ? exports : null; + +/** Detect free variable `module`. */ +var freeModule = (objectTypes[typeof module] && module && !module.nodeType) ? module : null; + +/** Detect free variable `global` from Node.js. */ +var freeGlobal = checkGlobal(freeExports && freeModule && typeof global == 'object' && global); + +/** Detect free variable `self`. */ +var freeSelf = checkGlobal(objectTypes[typeof self] && self); + +/** Detect free variable `window`. */ +var freeWindow = checkGlobal(objectTypes[typeof window] && window); + +/** Detect `this` as the global object. */ +var thisGlobal = checkGlobal(objectTypes[typeof this] && this); + +/** + * Used as a reference to the global object. + * + * The `this` value is used if it's the global object to avoid Greasemonkey's + * restricted `window` object, otherwise the `window` object is used. + */ +var root = freeGlobal || ((freeWindow !== (thisGlobal && thisGlobal.window)) && freeWindow) || freeSelf || thisGlobal || Function('return this')(); + +/** + * Checks if `value` is a global object. + * + * @private + * @param {*} value The value to check. + * @returns {null|Object} Returns `value` if it's a global object, else `null`. + */ +function checkGlobal(value) { + return (value && value.Object === Object) ? value : null; +} + /** * Gets the number of symbols in `string`. * @@ -92,7 +135,7 @@ function stringToArray(string) { } /** Used for built-in method references. */ -var objectProto = global.Object.prototype; +var objectProto = Object.prototype; /** * Used to resolve the [`toStringTag`](http://ecma-international.org/ecma-262/6.0/#sec-object.prototype.tostring) @@ -101,7 +144,7 @@ var objectProto = global.Object.prototype; var objectToString = objectProto.toString; /** Built-in value references. */ -var Symbol = global.Symbol; +var Symbol = root.Symbol; /* Built-in method references for those with the same name as other `lodash` methods. */ var nativeCeil = Math.ceil; diff --git a/lodash.padstart/package.json b/lodash.padstart/package.json index 6f8161bd2..c1ea59e12 100644 --- a/lodash.padstart/package.json +++ b/lodash.padstart/package.json @@ -1,11 +1,11 @@ { "name": "lodash.padstart", - "version": "4.0.1", + "version": "4.0.2", "description": "The lodash method `_.padStart` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", "license": "MIT", - "keywords": "lodash, lodash-modularized, stdlib, util, padstart", + "keywords": "lodash-modularized, padstart", "author": "John-David Dalton (http://allyoucanleet.com/)", "contributors": [ "John-David Dalton (http://allyoucanleet.com/)", diff --git a/lodash.parseint/LICENSE b/lodash.parseint/LICENSE index bcbe13d67..e0c69d560 100644 --- a/lodash.parseint/LICENSE +++ b/lodash.parseint/LICENSE @@ -1,23 +1,47 @@ -The MIT License (MIT) +Copyright jQuery Foundation and other contributors -Copyright 2012-2016 The Dojo Foundation -Based on Underscore.js, copyright 2009-2016 Jeremy Ashkenas, +Based on Underscore.js, copyright Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors -Permission is hereby granted, free of charge, to any person obtaining a copy -of this software and associated documentation files (the "Software"), to deal -in the Software without restriction, including without limitation the rights -to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the Software, and to permit persons to whom the Software is -furnished to do so, subject to the following conditions: +This software consists of voluntary contributions made by many +individuals. For exact contribution history, see the revision history +available at https://github.com/lodash/lodash -The above copyright notice and this permission notice shall be included in all -copies or substantial portions of the Software. +The following license applies to all parts of this software except as +documented below: -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE -SOFTWARE. +==== + +Permission is hereby granted, free of charge, to any person obtaining +a copy of this software and associated documentation files (the +"Software"), to deal in the Software without restriction, including +without limitation the rights to use, copy, modify, merge, publish, +distribute, sublicense, and/or sell copies of the Software, and to +permit persons to whom the Software is furnished to do so, subject to +the following conditions: + +The above copyright notice and this permission notice shall be +included in all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, +EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF +MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND +NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE +LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION +OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION +WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + +==== + +Copyright and related rights for sample code are waived via CC0. Sample +code is defined as all source code displayed within the prose of the +documentation. + +CC0: http://creativecommons.org/publicdomain/zero/1.0/ + +==== + +Files located in the node_modules and vendor directories are externally +maintained libraries used by this software which have their own +licenses; we recommend you read them, as their terms may differ from the +terms above. diff --git a/lodash.parseint/README.md b/lodash.parseint/README.md index 3b18083f9..cc50217f3 100644 --- a/lodash.parseint/README.md +++ b/lodash.parseint/README.md @@ -1,4 +1,4 @@ -# lodash.parseint v4.0.1 +# lodash.parseint v4.0.2 The [lodash](https://lodash.com/) method `_.parseInt` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var parseInt = require('lodash.parseint'); ``` -See the [documentation](https://lodash.com/docs#parseInt) or [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash.parseint) for more details. +See the [documentation](https://lodash.com/docs#parseInt) or [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash.parseint) for more details. diff --git a/lodash.parseint/index.js b/lodash.parseint/index.js index 13d0b61a3..b21e1328c 100644 --- a/lodash.parseint/index.js +++ b/lodash.parseint/index.js @@ -1,13 +1,17 @@ /** - * lodash 4.0.1 (Custom Build) + * lodash (Custom Build) * Build: `lodash modularize exports="npm" -o ./` - * Copyright 2012-2016 The Dojo Foundation + * Copyright jQuery Foundation and other contributors + * Released under MIT license * Based on Underscore.js 1.8.3 - * Copyright 2009-2016 Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors - * Available under MIT license + * Copyright Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors */ -var root = require('lodash._root'), - toString = require('lodash.tostring'); + +/** Used as references for various `Number` constants. */ +var INFINITY = 1 / 0; + +/** `Object#toString` result references. */ +var symbolTag = '[object Symbol]'; /** Used to match leading and trailing whitespace. */ var reTrim = /^\s+|\s+$/g; @@ -15,9 +19,130 @@ var reTrim = /^\s+|\s+$/g; /** Used to detect hexadecimal string values. */ var reHasHexPrefix = /^0x/i; +/** Detect free variable `global` from Node.js. */ +var freeGlobal = typeof global == 'object' && global && global.Object === Object && global; + +/** Detect free variable `self`. */ +var freeSelf = typeof self == 'object' && self && self.Object === Object && self; + +/** Used as a reference to the global object. */ +var root = freeGlobal || freeSelf || Function('return this')(); + +/** Used for built-in method references. */ +var objectProto = Object.prototype; + +/** + * Used to resolve the + * [`toStringTag`](http://ecma-international.org/ecma-262/7.0/#sec-object.prototype.tostring) + * of values. + */ +var objectToString = objectProto.toString; + +/** Built-in value references. */ +var Symbol = root.Symbol; + /* Built-in method references for those with the same name as other `lodash` methods. */ var nativeParseInt = root.parseInt; +/** Used to convert symbols to primitives and strings. */ +var symbolProto = Symbol ? Symbol.prototype : undefined, + symbolToString = symbolProto ? symbolProto.toString : undefined; + +/** + * The base implementation of `_.toString` which doesn't convert nullish + * values to empty strings. + * + * @private + * @param {*} value The value to process. + * @returns {string} Returns the string. + */ +function baseToString(value) { + // Exit early for strings to avoid a performance hit in some environments. + if (typeof value == 'string') { + return value; + } + if (isSymbol(value)) { + return symbolToString ? symbolToString.call(value) : ''; + } + var result = (value + ''); + return (result == '0' && (1 / value) == -INFINITY) ? '-0' : result; +} + +/** + * Checks if `value` is object-like. A value is object-like if it's not `null` + * and has a `typeof` result of "object". + * + * @static + * @memberOf _ + * @since 4.0.0 + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is object-like, else `false`. + * @example + * + * _.isObjectLike({}); + * // => true + * + * _.isObjectLike([1, 2, 3]); + * // => true + * + * _.isObjectLike(_.noop); + * // => false + * + * _.isObjectLike(null); + * // => false + */ +function isObjectLike(value) { + return !!value && typeof value == 'object'; +} + +/** + * Checks if `value` is classified as a `Symbol` primitive or object. + * + * @static + * @memberOf _ + * @since 4.0.0 + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is a symbol, else `false`. + * @example + * + * _.isSymbol(Symbol.iterator); + * // => true + * + * _.isSymbol('abc'); + * // => false + */ +function isSymbol(value) { + return typeof value == 'symbol' || + (isObjectLike(value) && objectToString.call(value) == symbolTag); +} + +/** + * Converts `value` to a string. An empty string is returned for `null` + * and `undefined` values. The sign of `-0` is preserved. + * + * @static + * @memberOf _ + * @since 4.0.0 + * @category Lang + * @param {*} value The value to process. + * @returns {string} Returns the string. + * @example + * + * _.toString(null); + * // => '' + * + * _.toString(-0); + * // => '-0' + * + * _.toString([1, 2, 3]); + * // => '1,2,3' + */ +function toString(value) { + return value == null ? '' : baseToString(value); +} + /** * Converts `string` to an integer of the specified radix. If `radix` is * `undefined` or `0`, a `radix` of `10` is used unless `value` is a diff --git a/lodash.parseint/package.json b/lodash.parseint/package.json index 2b5bb2e07..9bd19c856 100644 --- a/lodash.parseint/package.json +++ b/lodash.parseint/package.json @@ -1,6 +1,6 @@ { "name": "lodash.parseint", - "version": "4.0.1", + "version": "4.0.2", "description": "The lodash method `_.parseInt` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", @@ -13,9 +13,5 @@ "Mathias Bynens (https://mathiasbynens.be/)" ], "repository": "lodash/lodash", - "scripts": { "test": "echo \"See https://travis-ci.org/lodash/lodash-cli for testing details.\"" }, - "dependencies": { - "lodash._root": "~3.0.0", - "lodash.tostring": "^4.0.0" - } + "scripts": { "test": "echo \"See https://travis-ci.org/lodash/lodash-cli for testing details.\"" } } diff --git a/lodash.partition/README.md b/lodash.partition/README.md index 52f24a4b1..0754ebb6b 100644 --- a/lodash.partition/README.md +++ b/lodash.partition/README.md @@ -1,4 +1,4 @@ -# lodash.partition v4.0.1 +# lodash.partition v4.0.2 The [lodash](https://lodash.com/) method `_.partition` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var partition = require('lodash.partition'); ``` -See the [documentation](https://lodash.com/docs#partition) or [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash.partition) for more details. +See the [documentation](https://lodash.com/docs#partition) or [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash.partition) for more details. diff --git a/lodash.partition/index.js b/lodash.partition/index.js index f8713b5f3..ab81c4969 100644 --- a/lodash.partition/index.js +++ b/lodash.partition/index.js @@ -1,5 +1,5 @@ /** - * lodash 4.0.1 (Custom Build) + * lodash 4.0.2 (Custom Build) * Build: `lodash modularize exports="npm" -o ./` * Copyright 2012-2016 The Dojo Foundation * Based on Underscore.js 1.8.3 @@ -31,6 +31,27 @@ var reIsDeepProp = /\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/, /** Used to match backslashes in property paths. */ var reEscapeChar = /\\(\\)?/g; +/** + * A specialized version of `baseAggregator` for arrays. + * + * @private + * @param {Array} array The array to iterate over. + * @param {Function} setter The function to set `accumulator` values. + * @param {Function} iteratee The iteratee to transform keys. + * @param {Object} accumulator The initial aggregated object. + * @returns {Function} Returns `accumulator`. + */ +function arrayAggregator(array, setter, iteratee, accumulator) { + var index = -1, + length = array.length; + + while (++index < length) { + var value = array[index]; + setter(accumulator, value, iteratee(value), array); + } + return accumulator; +} + /** Used for built-in method references. */ var objectProto = global.Object.prototype; @@ -47,6 +68,24 @@ var Symbol = global.Symbol; var symbolProto = Symbol ? Symbol.prototype : undefined, symbolToString = Symbol ? symbolProto.toString : undefined; +/** + * Aggregates elements of `collection` on `accumulator` with keys transformed + * by `iteratee` and values set by `setter`. + * + * @private + * @param {Array|Object} collection The collection to iterate over. + * @param {Function} setter The function to set `accumulator` values. + * @param {Function} iteratee The iteratee to transform keys. + * @param {Object} accumulator The initial aggregated object. + * @returns {Function} Returns `accumulator`. + */ +function baseAggregator(collection, setter, iteratee, accumulator) { + baseEach(collection, function(value, key, collection) { + setter(accumulator, value, iteratee(value), collection); + }); + return accumulator; +} + /** * The base implementation of `_.get` without support for default values. * @@ -175,29 +214,16 @@ function baseToPath(value) { * Creates a function like `_.groupBy`. * * @private - * @param {Function} setter The function to set keys and values of the accumulator object. - * @param {Function} [initializer] The function to initialize the accumulator object. + * @param {Function} setter The function to set accumulator values. + * @param {Function} [initializer] The accumulator object initializer. * @returns {Function} Returns the new aggregator function. */ function createAggregator(setter, initializer) { return function(collection, iteratee) { - var result = initializer ? initializer() : {}; - iteratee = baseIteratee(iteratee); + var func = isArray(collection) ? arrayAggregator : baseAggregator, + accumulator = initializer ? initializer() : {}; - if (isArray(collection)) { - var index = -1, - length = collection.length; - - while (++index < length) { - var value = collection[index]; - setter(result, value, iteratee(value), collection); - } - } else { - baseEach(collection, function(value, key, collection) { - setter(result, value, iteratee(value), collection); - }); - } - return result; + return func(collection, setter, baseIteratee(iteratee), accumulator); }; } @@ -350,8 +376,6 @@ var isArray = Array.isArray; * // => false */ function isObject(value) { - // Avoid a V8 JIT bug in Chrome 19-20. - // See https://code.google.com/p/v8/issues/detail?id=2291 for more details. var type = typeof value; return !!value && (type == 'object' || type == 'function'); } diff --git a/lodash.partition/package.json b/lodash.partition/package.json index 4352c2c4f..ef672f062 100644 --- a/lodash.partition/package.json +++ b/lodash.partition/package.json @@ -1,11 +1,11 @@ { "name": "lodash.partition", - "version": "4.0.1", + "version": "4.0.2", "description": "The lodash method `_.partition` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", "license": "MIT", - "keywords": "lodash, lodash-modularized, stdlib, util, partition", + "keywords": "lodash-modularized, partition", "author": "John-David Dalton (http://allyoucanleet.com/)", "contributors": [ "John-David Dalton (http://allyoucanleet.com/)", diff --git a/lodash.pickby/README.md b/lodash.pickby/README.md index ba244c0a3..8df33673d 100644 --- a/lodash.pickby/README.md +++ b/lodash.pickby/README.md @@ -1,4 +1,4 @@ -# lodash.pickby v4.0.1 +# lodash.pickby v4.0.2 The [lodash](https://lodash.com/) method `_.pickBy` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var pickBy = require('lodash.pickby'); ``` -See the [documentation](https://lodash.com/docs#pickBy) or [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash.pickby) for more details. +See the [documentation](https://lodash.com/docs#pickBy) or [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash.pickby) for more details. diff --git a/lodash.pickby/index.js b/lodash.pickby/index.js index feaead2e7..e7f5b6590 100644 --- a/lodash.pickby/index.js +++ b/lodash.pickby/index.js @@ -1,5 +1,5 @@ /** - * lodash 4.0.1 (Custom Build) + * lodash 4.0.2 (Custom Build) * Build: `lodash modularize exports="npm" -o ./` * Copyright 2012-2016 The Dojo Foundation * Based on Underscore.js 1.8.3 @@ -32,8 +32,51 @@ var reIsDeepProp = /\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/, /** Used to match backslashes in property paths. */ var reEscapeChar = /\\(\\)?/g; +/** Used to determine if values are of the language type `Object`. */ +var objectTypes = { + 'function': true, + 'object': true +}; + +/** Detect free variable `exports`. */ +var freeExports = (objectTypes[typeof exports] && exports && !exports.nodeType) ? exports : null; + +/** Detect free variable `module`. */ +var freeModule = (objectTypes[typeof module] && module && !module.nodeType) ? module : null; + +/** Detect free variable `global` from Node.js. */ +var freeGlobal = checkGlobal(freeExports && freeModule && typeof global == 'object' && global); + +/** Detect free variable `self`. */ +var freeSelf = checkGlobal(objectTypes[typeof self] && self); + +/** Detect free variable `window`. */ +var freeWindow = checkGlobal(objectTypes[typeof window] && window); + +/** Detect `this` as the global object. */ +var thisGlobal = checkGlobal(objectTypes[typeof this] && this); + +/** + * Used as a reference to the global object. + * + * The `this` value is used if it's the global object to avoid Greasemonkey's + * restricted `window` object, otherwise the `window` object is used. + */ +var root = freeGlobal || ((freeWindow !== (thisGlobal && thisGlobal.window)) && freeWindow) || freeSelf || thisGlobal || Function('return this')(); + +/** + * Checks if `value` is a global object. + * + * @private + * @param {*} value The value to check. + * @returns {null|Object} Returns `value` if it's a global object, else `null`. + */ +function checkGlobal(value) { + return (value && value.Object === Object) ? value : null; +} + /** Used for built-in method references. */ -var objectProto = global.Object.prototype; +var objectProto = Object.prototype; /** * Used to resolve the [`toStringTag`](http://ecma-international.org/ecma-262/6.0/#sec-object.prototype.tostring) @@ -42,7 +85,7 @@ var objectProto = global.Object.prototype; var objectToString = objectProto.toString; /** Built-in value references. */ -var Symbol = global.Symbol; +var Symbol = root.Symbol; /** Used to convert symbols to primitives and strings. */ var symbolProto = Symbol ? Symbol.prototype : undefined, @@ -401,7 +444,7 @@ function toString(value) { /** * Creates an object composed of the `object` properties `predicate` returns - * truthy for. The predicate is invoked with one argument: (value). + * truthy for. The predicate is invoked with two arguments: (value, key). * * @static * @memberOf _ diff --git a/lodash.pickby/package.json b/lodash.pickby/package.json index af52b826e..236ed25fd 100644 --- a/lodash.pickby/package.json +++ b/lodash.pickby/package.json @@ -1,11 +1,11 @@ { "name": "lodash.pickby", - "version": "4.0.1", + "version": "4.0.2", "description": "The lodash method `_.pickBy` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", "license": "MIT", - "keywords": "lodash, lodash-modularized, stdlib, util, pickby", + "keywords": "lodash-modularized, pickby", "author": "John-David Dalton (http://allyoucanleet.com/)", "contributors": [ "John-David Dalton (http://allyoucanleet.com/)", diff --git a/lodash.property/README.md b/lodash.property/README.md index a27fbff50..065a98eea 100644 --- a/lodash.property/README.md +++ b/lodash.property/README.md @@ -1,4 +1,4 @@ -# lodash.property v4.0.1 +# lodash.property v4.0.2 The [lodash](https://lodash.com/) method `_.property` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var property = require('lodash.property'); ``` -See the [documentation](https://lodash.com/docs#property) or [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash.property) for more details. +See the [documentation](https://lodash.com/docs#property) or [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash.property) for more details. diff --git a/lodash.property/index.js b/lodash.property/index.js index d6d1ed6ce..9f707222b 100644 --- a/lodash.property/index.js +++ b/lodash.property/index.js @@ -1,5 +1,5 @@ /** - * lodash 4.0.1 (Custom Build) + * lodash 4.0.2 (Custom Build) * Build: `lodash modularize exports="npm" -o ./` * Copyright 2012-2016 The Dojo Foundation * Based on Underscore.js 1.8.3 @@ -21,8 +21,51 @@ var reIsDeepProp = /\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/, /** Used to match backslashes in property paths. */ var reEscapeChar = /\\(\\)?/g; +/** Used to determine if values are of the language type `Object`. */ +var objectTypes = { + 'function': true, + 'object': true +}; + +/** Detect free variable `exports`. */ +var freeExports = (objectTypes[typeof exports] && exports && !exports.nodeType) ? exports : null; + +/** Detect free variable `module`. */ +var freeModule = (objectTypes[typeof module] && module && !module.nodeType) ? module : null; + +/** Detect free variable `global` from Node.js. */ +var freeGlobal = checkGlobal(freeExports && freeModule && typeof global == 'object' && global); + +/** Detect free variable `self`. */ +var freeSelf = checkGlobal(objectTypes[typeof self] && self); + +/** Detect free variable `window`. */ +var freeWindow = checkGlobal(objectTypes[typeof window] && window); + +/** Detect `this` as the global object. */ +var thisGlobal = checkGlobal(objectTypes[typeof this] && this); + +/** + * Used as a reference to the global object. + * + * The `this` value is used if it's the global object to avoid Greasemonkey's + * restricted `window` object, otherwise the `window` object is used. + */ +var root = freeGlobal || ((freeWindow !== (thisGlobal && thisGlobal.window)) && freeWindow) || freeSelf || thisGlobal || Function('return this')(); + +/** + * Checks if `value` is a global object. + * + * @private + * @param {*} value The value to check. + * @returns {null|Object} Returns `value` if it's a global object, else `null`. + */ +function checkGlobal(value) { + return (value && value.Object === Object) ? value : null; +} + /** Used for built-in method references. */ -var objectProto = global.Object.prototype; +var objectProto = Object.prototype; /** * Used to resolve the [`toStringTag`](http://ecma-international.org/ecma-262/6.0/#sec-object.prototype.tostring) @@ -31,7 +74,7 @@ var objectProto = global.Object.prototype; var objectToString = objectProto.toString; /** Built-in value references. */ -var Symbol = global.Symbol; +var Symbol = root.Symbol; /** Used to convert symbols to primitives and strings. */ var symbolProto = Symbol ? Symbol.prototype : undefined, diff --git a/lodash.property/package.json b/lodash.property/package.json index 5c8983b2f..acedad561 100644 --- a/lodash.property/package.json +++ b/lodash.property/package.json @@ -1,11 +1,11 @@ { "name": "lodash.property", - "version": "4.0.1", + "version": "4.0.2", "description": "The lodash method `_.property` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", "license": "MIT", - "keywords": "lodash, lodash-modularized, stdlib, util, property", + "keywords": "lodash-modularized, property", "author": "John-David Dalton (http://allyoucanleet.com/)", "contributors": [ "John-David Dalton (http://allyoucanleet.com/)", diff --git a/lodash.propertyof/README.md b/lodash.propertyof/README.md index 3e2d196ed..f1f146790 100644 --- a/lodash.propertyof/README.md +++ b/lodash.propertyof/README.md @@ -1,4 +1,4 @@ -# lodash.propertyof v4.0.1 +# lodash.propertyof v4.0.2 The [lodash](https://lodash.com/) method `_.propertyOf` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var propertyOf = require('lodash.propertyof'); ``` -See the [documentation](https://lodash.com/docs#propertyOf) or [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash.propertyof) for more details. +See the [documentation](https://lodash.com/docs#propertyOf) or [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash.propertyof) for more details. diff --git a/lodash.propertyof/index.js b/lodash.propertyof/index.js index 1d126987e..34aff313d 100644 --- a/lodash.propertyof/index.js +++ b/lodash.propertyof/index.js @@ -1,5 +1,5 @@ /** - * lodash 4.0.1 (Custom Build) + * lodash 4.0.2 (Custom Build) * Build: `lodash modularize exports="npm" -o ./` * Copyright 2012-2016 The Dojo Foundation * Based on Underscore.js 1.8.3 @@ -21,8 +21,51 @@ var reIsDeepProp = /\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/, /** Used to match backslashes in property paths. */ var reEscapeChar = /\\(\\)?/g; +/** Used to determine if values are of the language type `Object`. */ +var objectTypes = { + 'function': true, + 'object': true +}; + +/** Detect free variable `exports`. */ +var freeExports = (objectTypes[typeof exports] && exports && !exports.nodeType) ? exports : null; + +/** Detect free variable `module`. */ +var freeModule = (objectTypes[typeof module] && module && !module.nodeType) ? module : null; + +/** Detect free variable `global` from Node.js. */ +var freeGlobal = checkGlobal(freeExports && freeModule && typeof global == 'object' && global); + +/** Detect free variable `self`. */ +var freeSelf = checkGlobal(objectTypes[typeof self] && self); + +/** Detect free variable `window`. */ +var freeWindow = checkGlobal(objectTypes[typeof window] && window); + +/** Detect `this` as the global object. */ +var thisGlobal = checkGlobal(objectTypes[typeof this] && this); + +/** + * Used as a reference to the global object. + * + * The `this` value is used if it's the global object to avoid Greasemonkey's + * restricted `window` object, otherwise the `window` object is used. + */ +var root = freeGlobal || ((freeWindow !== (thisGlobal && thisGlobal.window)) && freeWindow) || freeSelf || thisGlobal || Function('return this')(); + +/** + * Checks if `value` is a global object. + * + * @private + * @param {*} value The value to check. + * @returns {null|Object} Returns `value` if it's a global object, else `null`. + */ +function checkGlobal(value) { + return (value && value.Object === Object) ? value : null; +} + /** Used for built-in method references. */ -var objectProto = global.Object.prototype; +var objectProto = Object.prototype; /** * Used to resolve the [`toStringTag`](http://ecma-international.org/ecma-262/6.0/#sec-object.prototype.tostring) @@ -31,7 +74,7 @@ var objectProto = global.Object.prototype; var objectToString = objectProto.toString; /** Built-in value references. */ -var Symbol = global.Symbol; +var Symbol = root.Symbol; /** Used to convert symbols to primitives and strings. */ var symbolProto = Symbol ? Symbol.prototype : undefined, diff --git a/lodash.propertyof/package.json b/lodash.propertyof/package.json index b6c2e53fc..b5874f075 100644 --- a/lodash.propertyof/package.json +++ b/lodash.propertyof/package.json @@ -1,11 +1,11 @@ { "name": "lodash.propertyof", - "version": "4.0.1", + "version": "4.0.2", "description": "The lodash method `_.propertyOf` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", "license": "MIT", - "keywords": "lodash, lodash-modularized, stdlib, util, propertyof", + "keywords": "lodash-modularized, propertyof", "author": "John-David Dalton (http://allyoucanleet.com/)", "contributors": [ "John-David Dalton (http://allyoucanleet.com/)", diff --git a/lodash.pullallby/README.md b/lodash.pullallby/README.md index e9e88df5c..b38997c01 100644 --- a/lodash.pullallby/README.md +++ b/lodash.pullallby/README.md @@ -1,4 +1,4 @@ -# lodash.pullallby v4.0.1 +# lodash.pullallby v4.0.2 The [lodash](https://lodash.com/) method `_.pullAllBy` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var pullAllBy = require('lodash.pullallby'); ``` -See the [documentation](https://lodash.com/docs#pullAllBy) or [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash.pullallby) for more details. +See the [documentation](https://lodash.com/docs#pullAllBy) or [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash.pullallby) for more details. diff --git a/lodash.pullallby/index.js b/lodash.pullallby/index.js index 082526860..9f14d3709 100644 --- a/lodash.pullallby/index.js +++ b/lodash.pullallby/index.js @@ -1,5 +1,5 @@ /** - * lodash 4.0.0 (Custom Build) + * lodash 4.0.2 (Custom Build) * Build: `lodash modularize exports="npm" -o ./` * Copyright 2012-2016 The Dojo Foundation * Based on Underscore.js 1.8.3 @@ -41,11 +41,11 @@ var objectProto = global.Object.prototype; var objectToString = objectProto.toString; /** Built-in value references. */ -var _Symbol = global.Symbol; +var Symbol = global.Symbol; /** Used to convert symbols to primitives and strings. */ -var symbolProto = _Symbol ? _Symbol.prototype : undefined, - symbolToString = _Symbol ? symbolProto.toString : undefined; +var symbolProto = Symbol ? Symbol.prototype : undefined, + symbolToString = Symbol ? symbolProto.toString : undefined; /** * The base implementation of `_.get` without support for default values. @@ -309,8 +309,6 @@ var isArray = Array.isArray; * // => false */ function isObject(value) { - // Avoid a V8 JIT bug in Chrome 19-20. - // See https://code.google.com/p/v8/issues/detail?id=2291 for more details. var type = typeof value; return !!value && (type == 'object' || type == 'function'); } @@ -392,7 +390,7 @@ function toString(value) { return ''; } if (isSymbol(value)) { - return _Symbol ? symbolToString.call(value) : ''; + return Symbol ? symbolToString.call(value) : ''; } var result = (value + ''); return (result == '0' && (1 / value) == -INFINITY) ? '-0' : result; diff --git a/lodash.pullallby/package.json b/lodash.pullallby/package.json index e340dba3b..98e93d052 100644 --- a/lodash.pullallby/package.json +++ b/lodash.pullallby/package.json @@ -1,6 +1,6 @@ { "name": "lodash.pullallby", - "version": "4.0.1", + "version": "4.0.2", "description": "The lodash method `_.pullAllBy` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", diff --git a/lodash.rangeright/LICENSE b/lodash.rangeright/LICENSE index b054ca5a3..bcbe13d67 100644 --- a/lodash.rangeright/LICENSE +++ b/lodash.rangeright/LICENSE @@ -1,22 +1,23 @@ +The MIT License (MIT) + Copyright 2012-2016 The Dojo Foundation Based on Underscore.js, copyright 2009-2016 Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors -Permission is hereby granted, free of charge, to any person obtaining -a copy of this software and associated documentation files (the -"Software"), to deal in the Software without restriction, including -without limitation the rights to use, copy, modify, merge, publish, -distribute, sublicense, and/or sell copies of the Software, and to -permit persons to whom the Software is furnished to do so, subject to -the following conditions: +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: -The above copyright notice and this permission notice shall be -included in all copies or substantial portions of the Software. +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, -EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND -NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE -LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION -OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION -WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. diff --git a/lodash.rangeright/README.md b/lodash.rangeright/README.md index f4bca2c21..ac8eabcd4 100644 --- a/lodash.rangeright/README.md +++ b/lodash.rangeright/README.md @@ -1,4 +1,4 @@ -# lodash.rangeright v4.0.1 +# lodash.rangeright v4.0.2 The [lodash](https://lodash.com/) method `_.rangeRight` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var rangeRight = require('lodash.rangeright'); ``` -See the [documentation](https://lodash.com/docs#rangeRight) or [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash.rangeright) for more details. +See the [documentation](https://lodash.com/docs#rangeRight) or [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash.rangeright) for more details. diff --git a/lodash.rangeright/index.js b/lodash.rangeright/index.js index 80ef794d6..1043db237 100644 --- a/lodash.rangeright/index.js +++ b/lodash.rangeright/index.js @@ -1,5 +1,5 @@ /** - * lodash 4.0.1 (Custom Build) + * lodash 4.0.2 (Custom Build) * Build: `lodash modularize exports="npm" -o ./` * Copyright 2012-2016 The Dojo Foundation * Based on Underscore.js 1.8.3 @@ -197,7 +197,6 @@ function eq(value, other) { * * @static * @memberOf _ - * @type Function * @category Lang * @param {*} value The value to check. * @returns {boolean} Returns `true` if `value` is array-like, else `false`. @@ -269,7 +268,8 @@ function isFunction(value) { * // => false */ function isLength(value) { - return typeof value == 'number' && value > -1 && value % 1 == 0 && value <= MAX_SAFE_INTEGER; + return typeof value == 'number' && + value > -1 && value % 1 == 0 && value <= MAX_SAFE_INTEGER; } /** diff --git a/lodash.rangeright/package.json b/lodash.rangeright/package.json index 5b17f5411..0f851ece3 100644 --- a/lodash.rangeright/package.json +++ b/lodash.rangeright/package.json @@ -1,6 +1,6 @@ { "name": "lodash.rangeright", - "version": "4.0.1", + "version": "4.0.2", "description": "The lodash method `_.rangeRight` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", diff --git a/lodash.reduce/README.md b/lodash.reduce/README.md index b8b116fba..6b76e1d58 100644 --- a/lodash.reduce/README.md +++ b/lodash.reduce/README.md @@ -1,4 +1,4 @@ -# lodash.reduce v4.0.1 +# lodash.reduce v4.0.2 The [lodash](https://lodash.com/) method `_.reduce` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var reduce = require('lodash.reduce'); ``` -See the [documentation](https://lodash.com/docs#reduce) or [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash.reduce) for more details. +See the [documentation](https://lodash.com/docs#reduce) or [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash.reduce) for more details. diff --git a/lodash.reduce/index.js b/lodash.reduce/index.js index 435b4c8fc..65c45b7fb 100644 --- a/lodash.reduce/index.js +++ b/lodash.reduce/index.js @@ -1,5 +1,5 @@ /** - * lodash 4.0.1 (Custom Build) + * lodash 4.0.2 (Custom Build) * Build: `lodash modularize exports="npm" -o ./` * Copyright 2012-2016 The Dojo Foundation * Based on Underscore.js 1.8.3 @@ -32,6 +32,38 @@ var reIsDeepProp = /\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/, /** Used to match backslashes in property paths. */ var reEscapeChar = /\\(\\)?/g; +/** Used to determine if values are of the language type `Object`. */ +var objectTypes = { + 'function': true, + 'object': true +}; + +/** Detect free variable `exports`. */ +var freeExports = (objectTypes[typeof exports] && exports && !exports.nodeType) ? exports : null; + +/** Detect free variable `module`. */ +var freeModule = (objectTypes[typeof module] && module && !module.nodeType) ? module : null; + +/** Detect free variable `global` from Node.js. */ +var freeGlobal = checkGlobal(freeExports && freeModule && typeof global == 'object' && global); + +/** Detect free variable `self`. */ +var freeSelf = checkGlobal(objectTypes[typeof self] && self); + +/** Detect free variable `window`. */ +var freeWindow = checkGlobal(objectTypes[typeof window] && window); + +/** Detect `this` as the global object. */ +var thisGlobal = checkGlobal(objectTypes[typeof this] && this); + +/** + * Used as a reference to the global object. + * + * The `this` value is used if it's the global object to avoid Greasemonkey's + * restricted `window` object, otherwise the `window` object is used. + */ +var root = freeGlobal || ((freeWindow !== (thisGlobal && thisGlobal.window)) && freeWindow) || freeSelf || thisGlobal || Function('return this')(); + /** * A specialized version of `_.reduce` for arrays without support for * iteratee shorthands. @@ -56,8 +88,19 @@ function arrayReduce(array, iteratee, accumulator, initAccum) { return accumulator; } +/** + * Checks if `value` is a global object. + * + * @private + * @param {*} value The value to check. + * @returns {null|Object} Returns `value` if it's a global object, else `null`. + */ +function checkGlobal(value) { + return (value && value.Object === Object) ? value : null; +} + /** Used for built-in method references. */ -var objectProto = global.Object.prototype; +var objectProto = Object.prototype; /** * Used to resolve the [`toStringTag`](http://ecma-international.org/ecma-262/6.0/#sec-object.prototype.tostring) @@ -66,7 +109,7 @@ var objectProto = global.Object.prototype; var objectToString = objectProto.toString; /** Built-in value references. */ -var Symbol = global.Symbol; +var Symbol = root.Symbol; /** Used to convert symbols to primitives and strings. */ var symbolProto = Symbol ? Symbol.prototype : undefined, diff --git a/lodash.reduce/package.json b/lodash.reduce/package.json index cefbb40ff..2e3669ec8 100644 --- a/lodash.reduce/package.json +++ b/lodash.reduce/package.json @@ -1,11 +1,11 @@ { "name": "lodash.reduce", - "version": "4.0.1", + "version": "4.0.2", "description": "The lodash method `_.reduce` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", "license": "MIT", - "keywords": "lodash, lodash-modularized, stdlib, util, reduce", + "keywords": "lodash-modularized, reduce", "author": "John-David Dalton (http://allyoucanleet.com/)", "contributors": [ "John-David Dalton (http://allyoucanleet.com/)", diff --git a/lodash.reduceright/README.md b/lodash.reduceright/README.md index d8425c9c1..00c618dc7 100644 --- a/lodash.reduceright/README.md +++ b/lodash.reduceright/README.md @@ -1,4 +1,4 @@ -# lodash.reduceright v4.0.1 +# lodash.reduceright v4.0.2 The [lodash](https://lodash.com/) method `_.reduceRight` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var reduceRight = require('lodash.reduceright'); ``` -See the [documentation](https://lodash.com/docs#reduceRight) or [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash.reduceright) for more details. +See the [documentation](https://lodash.com/docs#reduceRight) or [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash.reduceright) for more details. diff --git a/lodash.reduceright/index.js b/lodash.reduceright/index.js index efdb65c0b..204b35795 100644 --- a/lodash.reduceright/index.js +++ b/lodash.reduceright/index.js @@ -1,5 +1,5 @@ /** - * lodash 4.0.1 (Custom Build) + * lodash 4.0.2 (Custom Build) * Build: `lodash modularize exports="npm" -o ./` * Copyright 2012-2016 The Dojo Foundation * Based on Underscore.js 1.8.3 @@ -32,6 +32,38 @@ var reIsDeepProp = /\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/, /** Used to match backslashes in property paths. */ var reEscapeChar = /\\(\\)?/g; +/** Used to determine if values are of the language type `Object`. */ +var objectTypes = { + 'function': true, + 'object': true +}; + +/** Detect free variable `exports`. */ +var freeExports = (objectTypes[typeof exports] && exports && !exports.nodeType) ? exports : null; + +/** Detect free variable `module`. */ +var freeModule = (objectTypes[typeof module] && module && !module.nodeType) ? module : null; + +/** Detect free variable `global` from Node.js. */ +var freeGlobal = checkGlobal(freeExports && freeModule && typeof global == 'object' && global); + +/** Detect free variable `self`. */ +var freeSelf = checkGlobal(objectTypes[typeof self] && self); + +/** Detect free variable `window`. */ +var freeWindow = checkGlobal(objectTypes[typeof window] && window); + +/** Detect `this` as the global object. */ +var thisGlobal = checkGlobal(objectTypes[typeof this] && this); + +/** + * Used as a reference to the global object. + * + * The `this` value is used if it's the global object to avoid Greasemonkey's + * restricted `window` object, otherwise the `window` object is used. + */ +var root = freeGlobal || ((freeWindow !== (thisGlobal && thisGlobal.window)) && freeWindow) || freeSelf || thisGlobal || Function('return this')(); + /** * A specialized version of `_.reduceRight` for arrays without support for * iteratee shorthands. @@ -54,8 +86,19 @@ function arrayReduceRight(array, iteratee, accumulator, initAccum) { return accumulator; } +/** + * Checks if `value` is a global object. + * + * @private + * @param {*} value The value to check. + * @returns {null|Object} Returns `value` if it's a global object, else `null`. + */ +function checkGlobal(value) { + return (value && value.Object === Object) ? value : null; +} + /** Used for built-in method references. */ -var objectProto = global.Object.prototype; +var objectProto = Object.prototype; /** * Used to resolve the [`toStringTag`](http://ecma-international.org/ecma-262/6.0/#sec-object.prototype.tostring) @@ -64,7 +107,7 @@ var objectProto = global.Object.prototype; var objectToString = objectProto.toString; /** Built-in value references. */ -var Symbol = global.Symbol; +var Symbol = root.Symbol; /** Used to convert symbols to primitives and strings. */ var symbolProto = Symbol ? Symbol.prototype : undefined, diff --git a/lodash.reduceright/package.json b/lodash.reduceright/package.json index 332eb70e7..cbf0e3f36 100644 --- a/lodash.reduceright/package.json +++ b/lodash.reduceright/package.json @@ -1,11 +1,11 @@ { "name": "lodash.reduceright", - "version": "4.0.1", + "version": "4.0.2", "description": "The lodash method `_.reduceRight` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", "license": "MIT", - "keywords": "lodash, lodash-modularized, stdlib, util, reduceright", + "keywords": "lodash-modularized, reduceright", "author": "John-David Dalton (http://allyoucanleet.com/)", "contributors": [ "John-David Dalton (http://allyoucanleet.com/)", diff --git a/lodash.reject/README.md b/lodash.reject/README.md index cfa4dd0bd..332f5530a 100644 --- a/lodash.reject/README.md +++ b/lodash.reject/README.md @@ -1,4 +1,4 @@ -# lodash.reject v4.0.1 +# lodash.reject v4.0.2 The [lodash](https://lodash.com/) method `_.reject` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var reject = require('lodash.reject'); ``` -See the [documentation](https://lodash.com/docs#reject) or [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash.reject) for more details. +See the [documentation](https://lodash.com/docs#reject) or [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash.reject) for more details. diff --git a/lodash.reject/index.js b/lodash.reject/index.js index ae4139729..8c0f1a915 100644 --- a/lodash.reject/index.js +++ b/lodash.reject/index.js @@ -1,5 +1,5 @@ /** - * lodash 4.0.1 (Custom Build) + * lodash 4.0.2 (Custom Build) * Build: `lodash modularize exports="npm" -o ./` * Copyright 2012-2016 The Dojo Foundation * Based on Underscore.js 1.8.3 @@ -32,8 +32,51 @@ var reIsDeepProp = /\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/, /** Used to match backslashes in property paths. */ var reEscapeChar = /\\(\\)?/g; +/** Used to determine if values are of the language type `Object`. */ +var objectTypes = { + 'function': true, + 'object': true +}; + +/** Detect free variable `exports`. */ +var freeExports = (objectTypes[typeof exports] && exports && !exports.nodeType) ? exports : null; + +/** Detect free variable `module`. */ +var freeModule = (objectTypes[typeof module] && module && !module.nodeType) ? module : null; + +/** Detect free variable `global` from Node.js. */ +var freeGlobal = checkGlobal(freeExports && freeModule && typeof global == 'object' && global); + +/** Detect free variable `self`. */ +var freeSelf = checkGlobal(objectTypes[typeof self] && self); + +/** Detect free variable `window`. */ +var freeWindow = checkGlobal(objectTypes[typeof window] && window); + +/** Detect `this` as the global object. */ +var thisGlobal = checkGlobal(objectTypes[typeof this] && this); + +/** + * Used as a reference to the global object. + * + * The `this` value is used if it's the global object to avoid Greasemonkey's + * restricted `window` object, otherwise the `window` object is used. + */ +var root = freeGlobal || ((freeWindow !== (thisGlobal && thisGlobal.window)) && freeWindow) || freeSelf || thisGlobal || Function('return this')(); + +/** + * Checks if `value` is a global object. + * + * @private + * @param {*} value The value to check. + * @returns {null|Object} Returns `value` if it's a global object, else `null`. + */ +function checkGlobal(value) { + return (value && value.Object === Object) ? value : null; +} + /** Used for built-in method references. */ -var objectProto = global.Object.prototype; +var objectProto = Object.prototype; /** * Used to resolve the [`toStringTag`](http://ecma-international.org/ecma-262/6.0/#sec-object.prototype.tostring) @@ -42,7 +85,7 @@ var objectProto = global.Object.prototype; var objectToString = objectProto.toString; /** Built-in value references. */ -var Symbol = global.Symbol; +var Symbol = root.Symbol; /** Used to convert symbols to primitives and strings. */ var symbolProto = Symbol ? Symbol.prototype : undefined, @@ -253,15 +296,15 @@ function stringToPath(string) { * _.reject(users, function(o) { return !o.active; }); * // => objects for ['fred'] * - * // using the `_.matches` iteratee shorthand + * // The `_.matches` iteratee shorthand. * _.reject(users, { 'age': 40, 'active': true }); * // => objects for ['barney'] * - * // using the `_.matchesProperty` iteratee shorthand + * // The `_.matchesProperty` iteratee shorthand. * _.reject(users, ['active', false]); * // => objects for ['fred'] * - * // using the `_.property` iteratee shorthand + * // The `_.property` iteratee shorthand. * _.reject(users, 'active'); * // => objects for ['barney'] */ diff --git a/lodash.reject/package.json b/lodash.reject/package.json index b319b6b5d..a8fd2c2ca 100644 --- a/lodash.reject/package.json +++ b/lodash.reject/package.json @@ -1,11 +1,11 @@ { "name": "lodash.reject", - "version": "4.0.1", + "version": "4.0.2", "description": "The lodash method `_.reject` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", "license": "MIT", - "keywords": "lodash, lodash-modularized, stdlib, util, reject", + "keywords": "lodash-modularized, reject", "author": "John-David Dalton (http://allyoucanleet.com/)", "contributors": [ "John-David Dalton (http://allyoucanleet.com/)", diff --git a/lodash.remove/README.md b/lodash.remove/README.md index 145fcbecb..473047c60 100644 --- a/lodash.remove/README.md +++ b/lodash.remove/README.md @@ -1,4 +1,4 @@ -# lodash.remove v4.0.1 +# lodash.remove v4.0.2 The [lodash](https://lodash.com/) method `_.remove` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var remove = require('lodash.remove'); ``` -See the [documentation](https://lodash.com/docs#remove) or [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash.remove) for more details. +See the [documentation](https://lodash.com/docs#remove) or [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash.remove) for more details. diff --git a/lodash.remove/index.js b/lodash.remove/index.js index 8248f9c58..3e438c460 100644 --- a/lodash.remove/index.js +++ b/lodash.remove/index.js @@ -1,5 +1,5 @@ /** - * lodash 4.0.1 (Custom Build) + * lodash 4.0.2 (Custom Build) * Build: `lodash modularize exports="npm" -o ./` * Copyright 2012-2016 The Dojo Foundation * Based on Underscore.js 1.8.3 @@ -31,8 +31,51 @@ var reIsDeepProp = /\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/, /** Used to match backslashes in property paths. */ var reEscapeChar = /\\(\\)?/g; +/** Used to determine if values are of the language type `Object`. */ +var objectTypes = { + 'function': true, + 'object': true +}; + +/** Detect free variable `exports`. */ +var freeExports = (objectTypes[typeof exports] && exports && !exports.nodeType) ? exports : null; + +/** Detect free variable `module`. */ +var freeModule = (objectTypes[typeof module] && module && !module.nodeType) ? module : null; + +/** Detect free variable `global` from Node.js. */ +var freeGlobal = checkGlobal(freeExports && freeModule && typeof global == 'object' && global); + +/** Detect free variable `self`. */ +var freeSelf = checkGlobal(objectTypes[typeof self] && self); + +/** Detect free variable `window`. */ +var freeWindow = checkGlobal(objectTypes[typeof window] && window); + +/** Detect `this` as the global object. */ +var thisGlobal = checkGlobal(objectTypes[typeof this] && this); + +/** + * Used as a reference to the global object. + * + * The `this` value is used if it's the global object to avoid Greasemonkey's + * restricted `window` object, otherwise the `window` object is used. + */ +var root = freeGlobal || ((freeWindow !== (thisGlobal && thisGlobal.window)) && freeWindow) || freeSelf || thisGlobal || Function('return this')(); + +/** + * Checks if `value` is a global object. + * + * @private + * @param {*} value The value to check. + * @returns {null|Object} Returns `value` if it's a global object, else `null`. + */ +function checkGlobal(value) { + return (value && value.Object === Object) ? value : null; +} + /** Used for built-in method references. */ -var objectProto = global.Object.prototype; +var objectProto = Object.prototype; /** * Used to resolve the [`toStringTag`](http://ecma-international.org/ecma-262/6.0/#sec-object.prototype.tostring) @@ -41,7 +84,7 @@ var objectProto = global.Object.prototype; var objectToString = objectProto.toString; /** Built-in value references. */ -var Symbol = global.Symbol; +var Symbol = root.Symbol; /** Used to convert symbols to primitives and strings. */ var symbolProto = Symbol ? Symbol.prototype : undefined, diff --git a/lodash.remove/package.json b/lodash.remove/package.json index e5e6e476d..a4f70f79e 100644 --- a/lodash.remove/package.json +++ b/lodash.remove/package.json @@ -1,11 +1,11 @@ { "name": "lodash.remove", - "version": "4.0.1", + "version": "4.0.2", "description": "The lodash method `_.remove` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", "license": "MIT", - "keywords": "lodash, lodash-modularized, stdlib, util, remove", + "keywords": "lodash-modularized, remove", "author": "John-David Dalton (http://allyoucanleet.com/)", "contributors": [ "John-David Dalton (http://allyoucanleet.com/)", diff --git a/lodash.repeat/README.md b/lodash.repeat/README.md index 9d875909d..9d626e83f 100644 --- a/lodash.repeat/README.md +++ b/lodash.repeat/README.md @@ -1,4 +1,4 @@ -# lodash.repeat v4.0.1 +# lodash.repeat v4.0.2 The [lodash](https://lodash.com/) method `_.repeat` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var repeat = require('lodash.repeat'); ``` -See the [documentation](https://lodash.com/docs#repeat) or [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash.repeat) for more details. +See the [documentation](https://lodash.com/docs#repeat) or [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash.repeat) for more details. diff --git a/lodash.repeat/index.js b/lodash.repeat/index.js index b56dfdfa1..5c2909731 100644 --- a/lodash.repeat/index.js +++ b/lodash.repeat/index.js @@ -1,5 +1,5 @@ /** - * lodash 4.0.1 (Custom Build) + * lodash 4.0.2 (Custom Build) * Build: `lodash modularize exports="npm" -o ./` * Copyright jQuery Foundation and other contributors * Released under MIT license @@ -31,14 +31,32 @@ var reIsBinary = /^0b[01]+$/i; /** Used to detect octal string values. */ var reIsOctal = /^0o[0-7]+$/i; +/** Used to detect unsigned integer values. */ +var reIsUint = /^(?:0|[1-9]\d*)$/; + /** Built-in method references without a dependency on `root`. */ var freeParseInt = parseInt; +/** + * Checks if `value` is a valid array-like index. + * + * @private + * @param {*} value The value to check. + * @param {number} [length=MAX_SAFE_INTEGER] The upper bounds of a valid index. + * @returns {boolean} Returns `true` if `value` is a valid index, else `false`. + */ +function isIndex(value, length) { + value = (typeof value == 'number' || reIsUint.test(value)) ? +value : -1; + length = length == null ? MAX_SAFE_INTEGER : length; + return value > -1 && value % 1 == 0 && value < length; +} + /** Used for built-in method references. */ var objectProto = Object.prototype; /** - * Used to resolve the [`toStringTag`](http://ecma-international.org/ecma-262/6.0/#sec-object.prototype.tostring) + * Used to resolve the + * [`toStringTag`](http://ecma-international.org/ecma-262/6.0/#sec-object.prototype.tostring) * of values. */ var objectToString = objectProto.toString; @@ -46,6 +64,19 @@ var objectToString = objectProto.toString; /* Built-in method references for those with the same name as other `lodash` methods. */ var nativeFloor = Math.floor; +/** + * The base implementation of `_.property` without support for deep paths. + * + * @private + * @param {string} key The key of the property to get. + * @returns {Function} Returns the new function. + */ +function baseProperty(key) { + return function(object) { + return object == null ? undefined : object[key]; + }; +} + /** * The base implementation of `_.repeat` which doesn't coerce arguments. * @@ -74,6 +105,108 @@ function baseRepeat(string, n) { return result; } +/** + * Gets the "length" property value of `object`. + * + * **Note:** This function is used to avoid a + * [JIT bug](https://bugs.webkit.org/show_bug.cgi?id=142792) that affects + * Safari on at least iOS 8.1-8.3 ARM64. + * + * @private + * @param {Object} object The object to query. + * @returns {*} Returns the "length" value. + */ +var getLength = baseProperty('length'); + +/** + * Checks if the given arguments are from an iteratee call. + * + * @private + * @param {*} value The potential iteratee value argument. + * @param {*} index The potential iteratee index or key argument. + * @param {*} object The potential iteratee object argument. + * @returns {boolean} Returns `true` if the arguments are from an iteratee call, + * else `false`. + */ +function isIterateeCall(value, index, object) { + if (!isObject(object)) { + return false; + } + var type = typeof index; + if (type == 'number' + ? (isArrayLike(object) && isIndex(index, object.length)) + : (type == 'string' && index in object) + ) { + return eq(object[index], value); + } + return false; +} + +/** + * Performs a + * [`SameValueZero`](http://ecma-international.org/ecma-262/6.0/#sec-samevaluezero) + * comparison between two values to determine if they are equivalent. + * + * @static + * @memberOf _ + * @since 4.0.0 + * @category Lang + * @param {*} value The value to compare. + * @param {*} other The other value to compare. + * @returns {boolean} Returns `true` if the values are equivalent, else `false`. + * @example + * + * var object = { 'user': 'fred' }; + * var other = { 'user': 'fred' }; + * + * _.eq(object, object); + * // => true + * + * _.eq(object, other); + * // => false + * + * _.eq('a', 'a'); + * // => true + * + * _.eq('a', Object('a')); + * // => false + * + * _.eq(NaN, NaN); + * // => true + */ +function eq(value, other) { + return value === other || (value !== value && other !== other); +} + +/** + * Checks if `value` is array-like. A value is considered array-like if it's + * not a function and has a `value.length` that's an integer greater than or + * equal to `0` and less than or equal to `Number.MAX_SAFE_INTEGER`. + * + * @static + * @memberOf _ + * @since 4.0.0 + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is array-like, else `false`. + * @example + * + * _.isArrayLike([1, 2, 3]); + * // => true + * + * _.isArrayLike(document.body.children); + * // => true + * + * _.isArrayLike('abc'); + * // => true + * + * _.isArrayLike(_.noop); + * // => false + */ +function isArrayLike(value) { + return value != null && isLength(getLength(value)) && !isFunction(value); +} + /** * Checks if `value` is classified as a `Function` object. * @@ -101,8 +234,41 @@ function isFunction(value) { } /** - * Checks if `value` is the [language type](https://es5.github.io/#x8) of `Object`. - * (e.g. arrays, functions, objects, regexes, `new Number(0)`, and `new String('')`) + * Checks if `value` is a valid array-like length. + * + * **Note:** This function is loosely based on + * [`ToLength`](http://ecma-international.org/ecma-262/6.0/#sec-tolength). + * + * @static + * @memberOf _ + * @since 4.0.0 + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is a valid length, + * else `false`. + * @example + * + * _.isLength(3); + * // => true + * + * _.isLength(Number.MIN_VALUE); + * // => false + * + * _.isLength(Infinity); + * // => false + * + * _.isLength('3'); + * // => false + */ +function isLength(value) { + return typeof value == 'number' && + value > -1 && value % 1 == 0 && value <= MAX_SAFE_INTEGER; +} + +/** + * Checks if `value` is the + * [language type](http://www.ecma-international.org/ecma-262/6.0/#sec-ecmascript-language-types) + * of `Object`. (e.g. arrays, functions, objects, regexes, `new Number(0)`, and `new String('')`) * * @static * @memberOf _ @@ -271,7 +437,8 @@ function toNumber(value) { * @since 3.0.0 * @category String * @param {string} [string=''] The string to repeat. - * @param {number} [n=0] The number of times to repeat the string. + * @param {number} [n=1] The number of times to repeat the string. + * @param- {Object} [guard] Enables use as an iteratee for methods like `_.map`. * @returns {string} Returns the repeated string. * @example * @@ -284,8 +451,13 @@ function toNumber(value) { * _.repeat('abc', 0); * // => '' */ -function repeat(string, n) { - return baseRepeat(toString(string), toInteger(n)); +function repeat(string, n, guard) { + if ((guard ? isIterateeCall(string, n, guard) : n === undefined)) { + n = 1; + } else { + n = toInteger(n); + } + return baseRepeat(toString(string), n); } module.exports = repeat; diff --git a/lodash.repeat/package.json b/lodash.repeat/package.json index 8e530c10d..9d947d7d2 100644 --- a/lodash.repeat/package.json +++ b/lodash.repeat/package.json @@ -1,6 +1,6 @@ { "name": "lodash.repeat", - "version": "4.0.1", + "version": "4.0.2", "description": "The lodash method `_.repeat` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", diff --git a/lodash.replace/README.md b/lodash.replace/README.md index b5c05f881..b14976df8 100644 --- a/lodash.replace/README.md +++ b/lodash.replace/README.md @@ -1,4 +1,4 @@ -# lodash.replace v4.0.1 +# lodash.replace v4.0.2 The [lodash](https://lodash.com/) method `_.replace` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var replace = require('lodash.replace'); ``` -See the [documentation](https://lodash.com/docs#replace) or [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash.replace) for more details. +See the [documentation](https://lodash.com/docs#replace) or [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash.replace) for more details. diff --git a/lodash.replace/index.js b/lodash.replace/index.js index d0186e10e..2645127ee 100644 --- a/lodash.replace/index.js +++ b/lodash.replace/index.js @@ -1,5 +1,5 @@ /** - * lodash 4.0.1 (Custom Build) + * lodash 4.0.2 (Custom Build) * Build: `lodash modularize exports="npm" -o ./` * Copyright 2012-2016 The Dojo Foundation * Based on Underscore.js 1.8.3 @@ -13,8 +13,51 @@ var INFINITY = 1 / 0; /** `Object#toString` result references. */ var symbolTag = '[object Symbol]'; +/** Used to determine if values are of the language type `Object`. */ +var objectTypes = { + 'function': true, + 'object': true +}; + +/** Detect free variable `exports`. */ +var freeExports = (objectTypes[typeof exports] && exports && !exports.nodeType) ? exports : null; + +/** Detect free variable `module`. */ +var freeModule = (objectTypes[typeof module] && module && !module.nodeType) ? module : null; + +/** Detect free variable `global` from Node.js. */ +var freeGlobal = checkGlobal(freeExports && freeModule && typeof global == 'object' && global); + +/** Detect free variable `self`. */ +var freeSelf = checkGlobal(objectTypes[typeof self] && self); + +/** Detect free variable `window`. */ +var freeWindow = checkGlobal(objectTypes[typeof window] && window); + +/** Detect `this` as the global object. */ +var thisGlobal = checkGlobal(objectTypes[typeof this] && this); + +/** + * Used as a reference to the global object. + * + * The `this` value is used if it's the global object to avoid Greasemonkey's + * restricted `window` object, otherwise the `window` object is used. + */ +var root = freeGlobal || ((freeWindow !== (thisGlobal && thisGlobal.window)) && freeWindow) || freeSelf || thisGlobal || Function('return this')(); + +/** + * Checks if `value` is a global object. + * + * @private + * @param {*} value The value to check. + * @returns {null|Object} Returns `value` if it's a global object, else `null`. + */ +function checkGlobal(value) { + return (value && value.Object === Object) ? value : null; +} + /** Used for built-in method references. */ -var objectProto = global.Object.prototype; +var objectProto = Object.prototype; /** * Used to resolve the [`toStringTag`](http://ecma-international.org/ecma-262/6.0/#sec-object.prototype.tostring) @@ -23,7 +66,7 @@ var objectProto = global.Object.prototype; var objectToString = objectProto.toString; /** Built-in value references. */ -var Symbol = global.Symbol; +var Symbol = root.Symbol; /** Used to convert symbols to primitives and strings. */ var symbolProto = Symbol ? Symbol.prototype : undefined, diff --git a/lodash.replace/package.json b/lodash.replace/package.json index 41cbc6e08..28c5d03a9 100644 --- a/lodash.replace/package.json +++ b/lodash.replace/package.json @@ -1,11 +1,11 @@ { "name": "lodash.replace", - "version": "4.0.1", + "version": "4.0.2", "description": "The lodash method `_.replace` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", "license": "MIT", - "keywords": "lodash, lodash-modularized, stdlib, util, replace", + "keywords": "lodash-modularized, replace", "author": "John-David Dalton (http://allyoucanleet.com/)", "contributors": [ "John-David Dalton (http://allyoucanleet.com/)", diff --git a/lodash.rest/LICENSE b/lodash.rest/LICENSE index b054ca5a3..e0c69d560 100644 --- a/lodash.rest/LICENSE +++ b/lodash.rest/LICENSE @@ -1,7 +1,17 @@ -Copyright 2012-2016 The Dojo Foundation -Based on Underscore.js, copyright 2009-2016 Jeremy Ashkenas, +Copyright jQuery Foundation and other contributors + +Based on Underscore.js, copyright Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors +This software consists of voluntary contributions made by many +individuals. For exact contribution history, see the revision history +available at https://github.com/lodash/lodash + +The following license applies to all parts of this software except as +documented below: + +==== + Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including @@ -20,3 +30,18 @@ NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + +==== + +Copyright and related rights for sample code are waived via CC0. Sample +code is defined as all source code displayed within the prose of the +documentation. + +CC0: http://creativecommons.org/publicdomain/zero/1.0/ + +==== + +Files located in the node_modules and vendor directories are externally +maintained libraries used by this software which have their own +licenses; we recommend you read them, as their terms may differ from the +terms above. diff --git a/lodash.rest/README.md b/lodash.rest/README.md index 8924e9d7f..5f1febeff 100644 --- a/lodash.rest/README.md +++ b/lodash.rest/README.md @@ -1,4 +1,4 @@ -# lodash.rest v4.0.1 +# lodash.rest v4.0.2 The [lodash](https://lodash.com/) method `_.rest` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var rest = require('lodash.rest'); ``` -See the [documentation](https://lodash.com/docs#rest) or [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash.rest) for more details. +See the [documentation](https://lodash.com/docs#rest) or [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash.rest) for more details. diff --git a/lodash.rest/index.js b/lodash.rest/index.js index 4fe746939..cd5831b84 100644 --- a/lodash.rest/index.js +++ b/lodash.rest/index.js @@ -1,10 +1,10 @@ /** - * lodash 4.0.1 (Custom Build) + * lodash 4.0.2 (Custom Build) * Build: `lodash modularize exports="npm" -o ./` - * Copyright 2012-2016 The Dojo Foundation + * Copyright jQuery Foundation and other contributors + * Released under MIT license * Based on Underscore.js 1.8.3 - * Copyright 2009-2016 Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors - * Available under MIT license + * Copyright Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors */ /** Used as the `TypeError` message for "Functions" methods. */ @@ -17,7 +17,8 @@ var INFINITY = 1 / 0, /** `Object#toString` result references. */ var funcTag = '[object Function]', - genTag = '[object GeneratorFunction]'; + genTag = '[object GeneratorFunction]', + symbolTag = '[object Symbol]'; /** Used to match leading and trailing whitespace. */ var reTrim = /^\s+|\s+$/g; @@ -41,7 +42,7 @@ var freeParseInt = parseInt; * @private * @param {Function} func The function to invoke. * @param {*} thisArg The `this` binding of `func`. - * @param {...*} args The arguments to invoke `func` with. + * @param {Array} args The arguments to invoke `func` with. * @returns {*} Returns the result of `func`. */ function apply(func, thisArg, args) { @@ -59,7 +60,8 @@ function apply(func, thisArg, args) { var objectProto = Object.prototype; /** - * Used to resolve the [`toStringTag`](http://ecma-international.org/ecma-262/6.0/#sec-object.prototype.tostring) + * Used to resolve the + * [`toStringTag`](http://ecma-international.org/ecma-262/6.0/#sec-object.prototype.tostring) * of values. */ var objectToString = objectProto.toString; @@ -69,12 +71,15 @@ var nativeMax = Math.max; /** * Creates a function that invokes `func` with the `this` binding of the - * created function and arguments from `start` and beyond provided as an array. + * created function and arguments from `start` and beyond provided as + * an array. * - * **Note:** This method is based on the [rest parameter](https://mdn.io/rest_parameters). + * **Note:** This method is based on the + * [rest parameter](https://mdn.io/rest_parameters). * * @static * @memberOf _ + * @since 4.0.0 * @category Function * @param {Function} func The function to apply a rest parameter to. * @param {number} [start=func.length-1] The start position of the rest parameter. @@ -123,9 +128,11 @@ function rest(func, start) { * * @static * @memberOf _ + * @since 0.1.0 * @category Lang * @param {*} value The value to check. - * @returns {boolean} Returns `true` if `value` is correctly classified, else `false`. + * @returns {boolean} Returns `true` if `value` is correctly classified, + * else `false`. * @example * * _.isFunction(_); @@ -143,11 +150,13 @@ function isFunction(value) { } /** - * Checks if `value` is the [language type](https://es5.github.io/#x8) of `Object`. - * (e.g. arrays, functions, objects, regexes, `new Number(0)`, and `new String('')`) + * Checks if `value` is the + * [language type](http://www.ecma-international.org/ecma-262/6.0/#sec-ecmascript-language-types) + * of `Object`. (e.g. arrays, functions, objects, regexes, `new Number(0)`, and `new String('')`) * * @static * @memberOf _ + * @since 0.1.0 * @category Lang * @param {*} value The value to check. * @returns {boolean} Returns `true` if `value` is an object, else `false`. @@ -171,12 +180,65 @@ function isObject(value) { } /** - * Converts `value` to an integer. - * - * **Note:** This function is loosely based on [`ToInteger`](http://www.ecma-international.org/ecma-262/6.0/#sec-tointeger). + * Checks if `value` is object-like. A value is object-like if it's not `null` + * and has a `typeof` result of "object". * * @static * @memberOf _ + * @since 4.0.0 + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is object-like, else `false`. + * @example + * + * _.isObjectLike({}); + * // => true + * + * _.isObjectLike([1, 2, 3]); + * // => true + * + * _.isObjectLike(_.noop); + * // => false + * + * _.isObjectLike(null); + * // => false + */ +function isObjectLike(value) { + return !!value && typeof value == 'object'; +} + +/** + * Checks if `value` is classified as a `Symbol` primitive or object. + * + * @static + * @memberOf _ + * @since 4.0.0 + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is correctly classified, + * else `false`. + * @example + * + * _.isSymbol(Symbol.iterator); + * // => true + * + * _.isSymbol('abc'); + * // => false + */ +function isSymbol(value) { + return typeof value == 'symbol' || + (isObjectLike(value) && objectToString.call(value) == symbolTag); +} + +/** + * Converts `value` to an integer. + * + * **Note:** This function is loosely based on + * [`ToInteger`](http://www.ecma-international.org/ecma-262/6.0/#sec-tointeger). + * + * @static + * @memberOf _ + * @since 4.0.0 * @category Lang * @param {*} value The value to convert. * @returns {number} Returns the converted integer. @@ -212,6 +274,7 @@ function toInteger(value) { * * @static * @memberOf _ + * @since 4.0.0 * @category Lang * @param {*} value The value to process. * @returns {number} Returns the number. @@ -230,6 +293,12 @@ function toInteger(value) { * // => 3 */ function toNumber(value) { + if (typeof value == 'number') { + return value; + } + if (isSymbol(value)) { + return NAN; + } if (isObject(value)) { var other = isFunction(value.valueOf) ? value.valueOf() : value; value = isObject(other) ? (other + '') : other; diff --git a/lodash.rest/package.json b/lodash.rest/package.json index 6eb6c00ea..8a3b2eb90 100644 --- a/lodash.rest/package.json +++ b/lodash.rest/package.json @@ -1,6 +1,6 @@ { "name": "lodash.rest", - "version": "4.0.1", + "version": "4.0.2", "description": "The lodash method `_.rest` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", @@ -9,7 +9,7 @@ "author": "John-David Dalton (http://allyoucanleet.com/)", "contributors": [ "John-David Dalton (http://allyoucanleet.com/)", - "Blaine Bublitz (https://github.com/phated)", + "Blaine Bublitz (https://github.com/phated)", "Mathias Bynens (https://mathiasbynens.be/)" ], "repository": "lodash/lodash", diff --git a/lodash.result/README.md b/lodash.result/README.md index 91dd44286..a9fc935ba 100644 --- a/lodash.result/README.md +++ b/lodash.result/README.md @@ -1,4 +1,4 @@ -# lodash.result v4.0.1 +# lodash.result v4.0.2 The [lodash](https://lodash.com/) method `_.result` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var result = require('lodash.result'); ``` -See the [documentation](https://lodash.com/docs#result) or [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash.result) for more details. +See the [documentation](https://lodash.com/docs#result) or [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash.result) for more details. diff --git a/lodash.result/index.js b/lodash.result/index.js index f470e9df3..765a87ef7 100644 --- a/lodash.result/index.js +++ b/lodash.result/index.js @@ -1,5 +1,5 @@ /** - * lodash 4.0.1 (Custom Build) + * lodash 4.0.2 (Custom Build) * Build: `lodash modularize exports="npm" -o ./` * Copyright 2012-2016 The Dojo Foundation * Based on Underscore.js 1.8.3 @@ -25,8 +25,51 @@ var reIsDeepProp = /\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/, /** Used to match backslashes in property paths. */ var reEscapeChar = /\\(\\)?/g; +/** Used to determine if values are of the language type `Object`. */ +var objectTypes = { + 'function': true, + 'object': true +}; + +/** Detect free variable `exports`. */ +var freeExports = (objectTypes[typeof exports] && exports && !exports.nodeType) ? exports : null; + +/** Detect free variable `module`. */ +var freeModule = (objectTypes[typeof module] && module && !module.nodeType) ? module : null; + +/** Detect free variable `global` from Node.js. */ +var freeGlobal = checkGlobal(freeExports && freeModule && typeof global == 'object' && global); + +/** Detect free variable `self`. */ +var freeSelf = checkGlobal(objectTypes[typeof self] && self); + +/** Detect free variable `window`. */ +var freeWindow = checkGlobal(objectTypes[typeof window] && window); + +/** Detect `this` as the global object. */ +var thisGlobal = checkGlobal(objectTypes[typeof this] && this); + +/** + * Used as a reference to the global object. + * + * The `this` value is used if it's the global object to avoid Greasemonkey's + * restricted `window` object, otherwise the `window` object is used. + */ +var root = freeGlobal || ((freeWindow !== (thisGlobal && thisGlobal.window)) && freeWindow) || freeSelf || thisGlobal || Function('return this')(); + +/** + * Checks if `value` is a global object. + * + * @private + * @param {*} value The value to check. + * @returns {null|Object} Returns `value` if it's a global object, else `null`. + */ +function checkGlobal(value) { + return (value && value.Object === Object) ? value : null; +} + /** Used for built-in method references. */ -var objectProto = global.Object.prototype; +var objectProto = Object.prototype; /** * Used to resolve the [`toStringTag`](http://ecma-international.org/ecma-262/6.0/#sec-object.prototype.tostring) @@ -35,7 +78,7 @@ var objectProto = global.Object.prototype; var objectToString = objectProto.toString; /** Built-in value references. */ -var Symbol = global.Symbol; +var Symbol = root.Symbol; /** Used to convert symbols to primitives and strings. */ var symbolProto = Symbol ? Symbol.prototype : undefined, diff --git a/lodash.result/package.json b/lodash.result/package.json index b03b0535d..f71b5e2f5 100644 --- a/lodash.result/package.json +++ b/lodash.result/package.json @@ -1,11 +1,11 @@ { "name": "lodash.result", - "version": "4.0.1", + "version": "4.0.2", "description": "The lodash method `_.result` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", "license": "MIT", - "keywords": "lodash, lodash-modularized, stdlib, util, result", + "keywords": "lodash-modularized, result", "author": "John-David Dalton (http://allyoucanleet.com/)", "contributors": [ "John-David Dalton (http://allyoucanleet.com/)", diff --git a/lodash.round/README.md b/lodash.round/README.md index b1e30900b..eb40f7697 100644 --- a/lodash.round/README.md +++ b/lodash.round/README.md @@ -1,4 +1,4 @@ -# lodash.round v4.0.1 +# lodash.round v4.0.2 The [lodash](https://lodash.com/) method `_.round` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var round = require('lodash.round'); ``` -See the [documentation](https://lodash.com/docs#round) or [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash.round) for more details. +See the [documentation](https://lodash.com/docs#round) or [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash.round) for more details. diff --git a/lodash.round/index.js b/lodash.round/index.js index 25528ffca..157d31641 100644 --- a/lodash.round/index.js +++ b/lodash.round/index.js @@ -1,5 +1,5 @@ /** - * lodash 4.0.1 (Custom Build) + * lodash (Custom Build) * Build: `lodash modularize exports="npm" -o ./` * Copyright jQuery Foundation and other contributors * Released under MIT license @@ -175,6 +175,41 @@ function isSymbol(value) { (isObjectLike(value) && objectToString.call(value) == symbolTag); } +/** + * Converts `value` to a finite number. + * + * @static + * @memberOf _ + * @since 4.12.0 + * @category Lang + * @param {*} value The value to convert. + * @returns {number} Returns the converted number. + * @example + * + * _.toFinite(3.2); + * // => 3.2 + * + * _.toFinite(Number.MIN_VALUE); + * // => 5e-324 + * + * _.toFinite(Infinity); + * // => 1.7976931348623157e+308 + * + * _.toFinite('3.2'); + * // => 3.2 + */ +function toFinite(value) { + if (!value) { + return value === 0 ? value : 0; + } + value = toNumber(value); + if (value === INFINITY || value === -INFINITY) { + var sign = (value < 0 ? -1 : 1); + return sign * MAX_INTEGER; + } + return value === value ? value : 0; +} + /** * Converts `value` to an integer. * @@ -189,7 +224,7 @@ function isSymbol(value) { * @returns {number} Returns the converted integer. * @example * - * _.toInteger(3); + * _.toInteger(3.2); * // => 3 * * _.toInteger(Number.MIN_VALUE); @@ -198,20 +233,14 @@ function isSymbol(value) { * _.toInteger(Infinity); * // => 1.7976931348623157e+308 * - * _.toInteger('3'); + * _.toInteger('3.2'); * // => 3 */ function toInteger(value) { - if (!value) { - return value === 0 ? value : 0; - } - value = toNumber(value); - if (value === INFINITY || value === -INFINITY) { - var sign = (value < 0 ? -1 : 1); - return sign * MAX_INTEGER; - } - var remainder = value % 1; - return value === value ? (remainder ? value - remainder : value) : 0; + var result = toFinite(value), + remainder = result % 1; + + return result === result ? (remainder ? result - remainder : result) : 0; } /** @@ -225,8 +254,8 @@ function toInteger(value) { * @returns {number} Returns the number. * @example * - * _.toNumber(3); - * // => 3 + * _.toNumber(3.2); + * // => 3.2 * * _.toNumber(Number.MIN_VALUE); * // => 5e-324 @@ -234,8 +263,8 @@ function toInteger(value) { * _.toNumber(Infinity); * // => Infinity * - * _.toNumber('3'); - * // => 3 + * _.toNumber('3.2'); + * // => 3.2 */ function toNumber(value) { if (typeof value == 'number') { diff --git a/lodash.round/package.json b/lodash.round/package.json index a5b7ba18c..70f9e4bcc 100644 --- a/lodash.round/package.json +++ b/lodash.round/package.json @@ -1,6 +1,6 @@ { "name": "lodash.round", - "version": "4.0.1", + "version": "4.0.2", "description": "The lodash method `_.round` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", diff --git a/lodash.samplesize/LICENSE b/lodash.samplesize/LICENSE index b054ca5a3..e0c69d560 100644 --- a/lodash.samplesize/LICENSE +++ b/lodash.samplesize/LICENSE @@ -1,7 +1,17 @@ -Copyright 2012-2016 The Dojo Foundation -Based on Underscore.js, copyright 2009-2016 Jeremy Ashkenas, +Copyright jQuery Foundation and other contributors + +Based on Underscore.js, copyright Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors +This software consists of voluntary contributions made by many +individuals. For exact contribution history, see the revision history +available at https://github.com/lodash/lodash + +The following license applies to all parts of this software except as +documented below: + +==== + Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including @@ -20,3 +30,18 @@ NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + +==== + +Copyright and related rights for sample code are waived via CC0. Sample +code is defined as all source code displayed within the prose of the +documentation. + +CC0: http://creativecommons.org/publicdomain/zero/1.0/ + +==== + +Files located in the node_modules and vendor directories are externally +maintained libraries used by this software which have their own +licenses; we recommend you read them, as their terms may differ from the +terms above. diff --git a/lodash.samplesize/README.md b/lodash.samplesize/README.md index eaa7a8287..e4d772a52 100644 --- a/lodash.samplesize/README.md +++ b/lodash.samplesize/README.md @@ -1,4 +1,4 @@ -# lodash.samplesize v4.0.1 +# lodash.samplesize v4.0.2 The [lodash](https://lodash.com/) method `_.sampleSize` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var sampleSize = require('lodash.samplesize'); ``` -See the [documentation](https://lodash.com/docs#sampleSize) or [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash.samplesize) for more details. +See the [documentation](https://lodash.com/docs#sampleSize) or [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash.samplesize) for more details. diff --git a/lodash.samplesize/index.js b/lodash.samplesize/index.js index 0a3c82e1e..bc965fbc2 100644 --- a/lodash.samplesize/index.js +++ b/lodash.samplesize/index.js @@ -1,10 +1,10 @@ /** - * lodash 4.0.1 (Custom Build) + * lodash 4.0.2 (Custom Build) * Build: `lodash modularize exports="npm" -o ./` - * Copyright 2012-2016 The Dojo Foundation + * Copyright jQuery Foundation and other contributors + * Released under MIT license * Based on Underscore.js 1.8.3 - * Copyright 2009-2016 Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors - * Available under MIT license + * Copyright Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors */ var toArray = require('lodash.toarray'); @@ -15,7 +15,8 @@ var INFINITY = 1 / 0, /** `Object#toString` result references. */ var funcTag = '[object Function]', - genTag = '[object GeneratorFunction]'; + genTag = '[object GeneratorFunction]', + symbolTag = '[object Symbol]'; /** Used to match leading and trailing whitespace. */ var reTrim = /^\s+|\s+$/g; @@ -85,6 +86,7 @@ function baseRandom(lower, upper) { * * @static * @memberOf _ + * @since 4.0.0 * @category Collection * @param {Array|Object} collection The collection to sample. * @param {number} [n=0] The number of elements to sample. @@ -120,9 +122,11 @@ function sampleSize(collection, n) { * * @static * @memberOf _ + * @since 0.1.0 * @category Lang * @param {*} value The value to check. - * @returns {boolean} Returns `true` if `value` is correctly classified, else `false`. + * @returns {boolean} Returns `true` if `value` is correctly classified, + * else `false`. * @example * * _.isFunction(_); @@ -145,6 +149,7 @@ function isFunction(value) { * * @static * @memberOf _ + * @since 0.1.0 * @category Lang * @param {*} value The value to check. * @returns {boolean} Returns `true` if `value` is an object, else `false`. @@ -168,12 +173,65 @@ function isObject(value) { } /** - * Converts `value` to an integer. - * - * **Note:** This function is loosely based on [`ToInteger`](http://www.ecma-international.org/ecma-262/6.0/#sec-tointeger). + * Checks if `value` is object-like. A value is object-like if it's not `null` + * and has a `typeof` result of "object". * * @static * @memberOf _ + * @since 4.0.0 + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is object-like, else `false`. + * @example + * + * _.isObjectLike({}); + * // => true + * + * _.isObjectLike([1, 2, 3]); + * // => true + * + * _.isObjectLike(_.noop); + * // => false + * + * _.isObjectLike(null); + * // => false + */ +function isObjectLike(value) { + return !!value && typeof value == 'object'; +} + +/** + * Checks if `value` is classified as a `Symbol` primitive or object. + * + * @static + * @memberOf _ + * @since 4.0.0 + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is correctly classified, + * else `false`. + * @example + * + * _.isSymbol(Symbol.iterator); + * // => true + * + * _.isSymbol('abc'); + * // => false + */ +function isSymbol(value) { + return typeof value == 'symbol' || + (isObjectLike(value) && objectToString.call(value) == symbolTag); +} + +/** + * Converts `value` to an integer. + * + * **Note:** This function is loosely based on + * [`ToInteger`](http://www.ecma-international.org/ecma-262/6.0/#sec-tointeger). + * + * @static + * @memberOf _ + * @since 4.0.0 * @category Lang * @param {*} value The value to convert. * @returns {number} Returns the converted integer. @@ -209,6 +267,7 @@ function toInteger(value) { * * @static * @memberOf _ + * @since 4.0.0 * @category Lang * @param {*} value The value to process. * @returns {number} Returns the number. @@ -227,6 +286,12 @@ function toInteger(value) { * // => 3 */ function toNumber(value) { + if (typeof value == 'number') { + return value; + } + if (isSymbol(value)) { + return NAN; + } if (isObject(value)) { var other = isFunction(value.valueOf) ? value.valueOf() : value; value = isObject(other) ? (other + '') : other; diff --git a/lodash.samplesize/package.json b/lodash.samplesize/package.json index 1aa38704a..0a8fb48cb 100644 --- a/lodash.samplesize/package.json +++ b/lodash.samplesize/package.json @@ -1,6 +1,6 @@ { "name": "lodash.samplesize", - "version": "4.0.1", + "version": "4.0.2", "description": "The lodash method `_.sampleSize` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", @@ -9,7 +9,7 @@ "author": "John-David Dalton (http://allyoucanleet.com/)", "contributors": [ "John-David Dalton (http://allyoucanleet.com/)", - "Blaine Bublitz (https://github.com/phated)", + "Blaine Bublitz (https://github.com/phated)", "Mathias Bynens (https://mathiasbynens.be/)" ], "repository": "lodash/lodash", diff --git a/lodash.size/README.md b/lodash.size/README.md index f288f829d..189f7f0b9 100644 --- a/lodash.size/README.md +++ b/lodash.size/README.md @@ -1,4 +1,4 @@ -# lodash.size v4.0.1 +# lodash.size v4.0.2 The [lodash](https://lodash.com/) method `_.size` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var size = require('lodash.size'); ``` -See the [documentation](https://lodash.com/docs#size) or [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash.size) for more details. +See the [documentation](https://lodash.com/docs#size) or [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash.size) for more details. diff --git a/lodash.size/index.js b/lodash.size/index.js index 73f82a997..920faa678 100644 --- a/lodash.size/index.js +++ b/lodash.size/index.js @@ -1,5 +1,5 @@ /** - * lodash 4.0.1 (Custom Build) + * lodash 4.0.2 (Custom Build) * Build: `lodash modularize exports="npm" -o ./` * Copyright 2012-2016 The Dojo Foundation * Based on Underscore.js 1.8.3 @@ -64,7 +64,7 @@ function stringSize(string) { } /** Used for built-in method references. */ -var objectProto = global.Object.prototype; +var objectProto = Object.prototype; /** * Used to resolve the [`toStringTag`](http://ecma-international.org/ecma-262/6.0/#sec-object.prototype.tostring) diff --git a/lodash.size/package.json b/lodash.size/package.json index 7b0059eb1..1e5b89771 100644 --- a/lodash.size/package.json +++ b/lodash.size/package.json @@ -1,11 +1,11 @@ { "name": "lodash.size", - "version": "4.0.1", + "version": "4.0.2", "description": "The lodash method `_.size` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", "license": "MIT", - "keywords": "lodash, lodash-modularized, stdlib, util, size", + "keywords": "lodash-modularized, size", "author": "John-David Dalton (http://allyoucanleet.com/)", "contributors": [ "John-David Dalton (http://allyoucanleet.com/)", diff --git a/lodash.slice/LICENSE b/lodash.slice/LICENSE index b054ca5a3..bcbe13d67 100644 --- a/lodash.slice/LICENSE +++ b/lodash.slice/LICENSE @@ -1,22 +1,23 @@ +The MIT License (MIT) + Copyright 2012-2016 The Dojo Foundation Based on Underscore.js, copyright 2009-2016 Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors -Permission is hereby granted, free of charge, to any person obtaining -a copy of this software and associated documentation files (the -"Software"), to deal in the Software without restriction, including -without limitation the rights to use, copy, modify, merge, publish, -distribute, sublicense, and/or sell copies of the Software, and to -permit persons to whom the Software is furnished to do so, subject to -the following conditions: +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: -The above copyright notice and this permission notice shall be -included in all copies or substantial portions of the Software. +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, -EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND -NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE -LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION -OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION -WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. diff --git a/lodash.slice/README.md b/lodash.slice/README.md index a97cbb5a3..b5aa27b91 100644 --- a/lodash.slice/README.md +++ b/lodash.slice/README.md @@ -1,4 +1,4 @@ -# lodash.slice v4.0.1 +# lodash.slice v4.0.2 The [lodash](https://lodash.com/) method `_.slice` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var slice = require('lodash.slice'); ``` -See the [documentation](https://lodash.com/docs#slice) or [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash.slice) for more details. +See the [documentation](https://lodash.com/docs#slice) or [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash.slice) for more details. diff --git a/lodash.slice/index.js b/lodash.slice/index.js index 279755c1e..1f6f92436 100644 --- a/lodash.slice/index.js +++ b/lodash.slice/index.js @@ -1,5 +1,5 @@ /** - * lodash 4.0.1 (Custom Build) + * lodash 4.0.2 (Custom Build) * Build: `lodash modularize exports="npm" -o ./` * Copyright 2012-2016 The Dojo Foundation * Based on Underscore.js 1.8.3 @@ -177,7 +177,6 @@ function eq(value, other) { * * @static * @memberOf _ - * @type Function * @category Lang * @param {*} value The value to check. * @returns {boolean} Returns `true` if `value` is array-like, else `false`. @@ -249,7 +248,8 @@ function isFunction(value) { * // => false */ function isLength(value) { - return typeof value == 'number' && value > -1 && value % 1 == 0 && value <= MAX_SAFE_INTEGER; + return typeof value == 'number' && + value > -1 && value % 1 == 0 && value <= MAX_SAFE_INTEGER; } /** diff --git a/lodash.slice/package.json b/lodash.slice/package.json index 3693e9d29..5620d3b7f 100644 --- a/lodash.slice/package.json +++ b/lodash.slice/package.json @@ -1,6 +1,6 @@ { "name": "lodash.slice", - "version": "4.0.1", + "version": "4.0.2", "description": "The lodash method `_.slice` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", diff --git a/lodash.some/README.md b/lodash.some/README.md index efc20dd76..2dd89309d 100644 --- a/lodash.some/README.md +++ b/lodash.some/README.md @@ -1,4 +1,4 @@ -# lodash.some v4.0.1 +# lodash.some v4.0.2 The [lodash](https://lodash.com/) method `_.some` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var some = require('lodash.some'); ``` -See the [documentation](https://lodash.com/docs#some) or [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash.some) for more details. +See the [documentation](https://lodash.com/docs#some) or [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash.some) for more details. diff --git a/lodash.some/index.js b/lodash.some/index.js index 50f10191c..103cf106c 100644 --- a/lodash.some/index.js +++ b/lodash.some/index.js @@ -1,5 +1,5 @@ /** - * lodash 4.0.1 (Custom Build) + * lodash 4.0.2 (Custom Build) * Build: `lodash modularize exports="npm" -o ./` * Copyright 2012-2016 The Dojo Foundation * Based on Underscore.js 1.8.3 @@ -37,6 +37,38 @@ var reEscapeChar = /\\(\\)?/g; /** Used to detect unsigned integer values. */ var reIsUint = /^(?:0|[1-9]\d*)$/; +/** Used to determine if values are of the language type `Object`. */ +var objectTypes = { + 'function': true, + 'object': true +}; + +/** Detect free variable `exports`. */ +var freeExports = (objectTypes[typeof exports] && exports && !exports.nodeType) ? exports : null; + +/** Detect free variable `module`. */ +var freeModule = (objectTypes[typeof module] && module && !module.nodeType) ? module : null; + +/** Detect free variable `global` from Node.js. */ +var freeGlobal = checkGlobal(freeExports && freeModule && typeof global == 'object' && global); + +/** Detect free variable `self`. */ +var freeSelf = checkGlobal(objectTypes[typeof self] && self); + +/** Detect free variable `window`. */ +var freeWindow = checkGlobal(objectTypes[typeof window] && window); + +/** Detect `this` as the global object. */ +var thisGlobal = checkGlobal(objectTypes[typeof this] && this); + +/** + * Used as a reference to the global object. + * + * The `this` value is used if it's the global object to avoid Greasemonkey's + * restricted `window` object, otherwise the `window` object is used. + */ +var root = freeGlobal || ((freeWindow !== (thisGlobal && thisGlobal.window)) && freeWindow) || freeSelf || thisGlobal || Function('return this')(); + /** * A specialized version of `_.some` for arrays without support for iteratee * shorthands. @@ -58,6 +90,17 @@ function arraySome(array, predicate) { return false; } +/** + * Checks if `value` is a global object. + * + * @private + * @param {*} value The value to check. + * @returns {null|Object} Returns `value` if it's a global object, else `null`. + */ +function checkGlobal(value) { + return (value && value.Object === Object) ? value : null; +} + /** * Checks if `value` is a valid array-like index. * @@ -73,7 +116,7 @@ function isIndex(value, length) { } /** Used for built-in method references. */ -var objectProto = global.Object.prototype; +var objectProto = Object.prototype; /** * Used to resolve the [`toStringTag`](http://ecma-international.org/ecma-262/6.0/#sec-object.prototype.tostring) @@ -82,7 +125,7 @@ var objectProto = global.Object.prototype; var objectToString = objectProto.toString; /** Built-in value references. */ -var Symbol = global.Symbol; +var Symbol = root.Symbol; /** Used to convert symbols to primitives and strings. */ var symbolProto = Symbol ? Symbol.prototype : undefined, @@ -347,15 +390,15 @@ function stringToPath(string) { * { 'user': 'fred', 'active': false } * ]; * - * // using the `_.matches` iteratee shorthand + * // The `_.matches` iteratee shorthand. * _.some(users, { 'user': 'barney', 'active': false }); * // => false * - * // using the `_.matchesProperty` iteratee shorthand + * // The `_.matchesProperty` iteratee shorthand. * _.some(users, ['active', false]); * // => true * - * // using the `_.property` iteratee shorthand + * // The `_.property` iteratee shorthand. * _.some(users, 'active'); * // => true */ diff --git a/lodash.some/package.json b/lodash.some/package.json index e34a77340..5af8c43f3 100644 --- a/lodash.some/package.json +++ b/lodash.some/package.json @@ -1,11 +1,11 @@ { "name": "lodash.some", - "version": "4.0.1", + "version": "4.0.2", "description": "The lodash method `_.some` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", "license": "MIT", - "keywords": "lodash, lodash-modularized, stdlib, util, some", + "keywords": "lodash-modularized, some", "author": "John-David Dalton (http://allyoucanleet.com/)", "contributors": [ "John-David Dalton (http://allyoucanleet.com/)", diff --git a/lodash.sortby/README.md b/lodash.sortby/README.md index 1b3bdc34d..862647e41 100644 --- a/lodash.sortby/README.md +++ b/lodash.sortby/README.md @@ -1,4 +1,4 @@ -# lodash.sortby v4.0.1 +# lodash.sortby v4.0.2 The [lodash](https://lodash.com/) method `_.sortBy` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var sortBy = require('lodash.sortby'); ``` -See the [documentation](https://lodash.com/docs#sortBy) or [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash.sortby) for more details. +See the [documentation](https://lodash.com/docs#sortBy) or [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash.sortby) for more details. diff --git a/lodash.sortby/index.js b/lodash.sortby/index.js index 9bc0d8511..f4a33da69 100644 --- a/lodash.sortby/index.js +++ b/lodash.sortby/index.js @@ -1,5 +1,5 @@ /** - * lodash 4.0.1 (Custom Build) + * lodash 4.0.2 (Custom Build) * Build: `lodash modularize exports="npm" -o ./` * Copyright 2012-2016 The Dojo Foundation * Based on Underscore.js 1.8.3 @@ -40,6 +40,38 @@ var reEscapeChar = /\\(\\)?/g; /** Used to detect unsigned integer values. */ var reIsUint = /^(?:0|[1-9]\d*)$/; +/** Used to determine if values are of the language type `Object`. */ +var objectTypes = { + 'function': true, + 'object': true +}; + +/** Detect free variable `exports`. */ +var freeExports = (objectTypes[typeof exports] && exports && !exports.nodeType) ? exports : null; + +/** Detect free variable `module`. */ +var freeModule = (objectTypes[typeof module] && module && !module.nodeType) ? module : null; + +/** Detect free variable `global` from Node.js. */ +var freeGlobal = checkGlobal(freeExports && freeModule && typeof global == 'object' && global); + +/** Detect free variable `self`. */ +var freeSelf = checkGlobal(objectTypes[typeof self] && self); + +/** Detect free variable `window`. */ +var freeWindow = checkGlobal(objectTypes[typeof window] && window); + +/** Detect `this` as the global object. */ +var thisGlobal = checkGlobal(objectTypes[typeof this] && this); + +/** + * Used as a reference to the global object. + * + * The `this` value is used if it's the global object to avoid Greasemonkey's + * restricted `window` object, otherwise the `window` object is used. + */ +var root = freeGlobal || ((freeWindow !== (thisGlobal && thisGlobal.window)) && freeWindow) || freeSelf || thisGlobal || Function('return this')(); + /** * The base implementation of `_.sortBy` which uses `comparer` to define * the sort order of `array` and replaces criteria objects with their @@ -60,6 +92,17 @@ function baseSortBy(array, comparer) { return array; } +/** + * Checks if `value` is a global object. + * + * @private + * @param {*} value The value to check. + * @returns {null|Object} Returns `value` if it's a global object, else `null`. + */ +function checkGlobal(value) { + return (value && value.Object === Object) ? value : null; +} + /** * Compares values to sort them in ascending order. * @@ -148,7 +191,7 @@ function isIndex(value, length) { } /** Used for built-in method references. */ -var objectProto = global.Object.prototype; +var objectProto = Object.prototype; /** * Used to resolve the [`toStringTag`](http://ecma-international.org/ecma-262/6.0/#sec-object.prototype.tostring) @@ -157,7 +200,7 @@ var objectProto = global.Object.prototype; var objectToString = objectProto.toString; /** Built-in value references. */ -var Symbol = global.Symbol; +var Symbol = root.Symbol; /** Used to convert symbols to primitives and strings. */ var symbolProto = Symbol ? Symbol.prototype : undefined, diff --git a/lodash.sortby/package.json b/lodash.sortby/package.json index ddf4201a5..2a84fef83 100644 --- a/lodash.sortby/package.json +++ b/lodash.sortby/package.json @@ -1,11 +1,11 @@ { "name": "lodash.sortby", - "version": "4.0.1", + "version": "4.0.2", "description": "The lodash method `_.sortBy` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", "license": "MIT", - "keywords": "lodash, lodash-modularized, stdlib, util, sortby", + "keywords": "lodash-modularized, sortby", "author": "John-David Dalton (http://allyoucanleet.com/)", "contributors": [ "John-David Dalton (http://allyoucanleet.com/)", diff --git a/lodash.sortedindex/LICENSE b/lodash.sortedindex/LICENSE index b054ca5a3..bcbe13d67 100644 --- a/lodash.sortedindex/LICENSE +++ b/lodash.sortedindex/LICENSE @@ -1,22 +1,23 @@ +The MIT License (MIT) + Copyright 2012-2016 The Dojo Foundation Based on Underscore.js, copyright 2009-2016 Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors -Permission is hereby granted, free of charge, to any person obtaining -a copy of this software and associated documentation files (the -"Software"), to deal in the Software without restriction, including -without limitation the rights to use, copy, modify, merge, publish, -distribute, sublicense, and/or sell copies of the Software, and to -permit persons to whom the Software is furnished to do so, subject to -the following conditions: +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: -The above copyright notice and this permission notice shall be -included in all copies or substantial portions of the Software. +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, -EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND -NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE -LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION -OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION -WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. diff --git a/lodash.sortedindex/README.md b/lodash.sortedindex/README.md index 28f7ad11c..2b92712e9 100644 --- a/lodash.sortedindex/README.md +++ b/lodash.sortedindex/README.md @@ -1,4 +1,4 @@ -# lodash.sortedindex v4.0.1 +# lodash.sortedindex v4.0.2 The [lodash](https://lodash.com/) method `_.sortedIndex` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var sortedIndex = require('lodash.sortedindex'); ``` -See the [documentation](https://lodash.com/docs#sortedIndex) or [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash.sortedindex) for more details. +See the [documentation](https://lodash.com/docs#sortedIndex) or [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash.sortedindex) for more details. diff --git a/lodash.sortedindex/index.js b/lodash.sortedindex/index.js index 2ac3a2b1a..0ecfe0e28 100644 --- a/lodash.sortedindex/index.js +++ b/lodash.sortedindex/index.js @@ -1,5 +1,5 @@ /** - * lodash 4.0.1 (Custom Build) + * lodash 4.0.2 (Custom Build) * Build: `lodash modularize exports="npm" -o ./` * Copyright 2012-2016 The Dojo Foundation * Based on Underscore.js 1.8.3 @@ -45,15 +45,17 @@ function baseSortedIndex(array, value, retHighest) { } /** - * Uses a binary search to determine the lowest index at which `value` should - * be inserted into `array` in order to maintain its sort order. + * Uses a binary search to determine the lowest index at which `value` + * should be inserted into `array` in order to maintain its sort order. * * @static * @memberOf _ + * @since 0.1.0 * @category Array * @param {Array} array The sorted array to inspect. * @param {*} value The value to evaluate. - * @returns {number} Returns the index at which `value` should be inserted into `array`. + * @returns {number} Returns the index at which `value` should be inserted + * into `array`. * @example * * _.sortedIndex([30, 50], 40); @@ -70,6 +72,7 @@ function sortedIndex(array, value) { * This method returns the first argument given to it. * * @static + * @since 0.1.0 * @memberOf _ * @category Util * @param {*} value Any value. diff --git a/lodash.sortedindex/package.json b/lodash.sortedindex/package.json index 476ec4c51..1ec2cc6c0 100644 --- a/lodash.sortedindex/package.json +++ b/lodash.sortedindex/package.json @@ -1,20 +1,20 @@ { "name": "lodash.sortedindex", - "version": "4.0.1", + "version": "4.0.2", "description": "The lodash method `_.sortedIndex` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", "license": "MIT", - "keywords": "lodash, lodash-modularized, stdlib, util, sortedindex", + "keywords": "lodash-modularized, sortedindex", "author": "John-David Dalton (http://allyoucanleet.com/)", "contributors": [ "John-David Dalton (http://allyoucanleet.com/)", - "Blaine Bublitz (https://github.com/phated)", + "Blaine Bublitz (https://github.com/phated)", "Mathias Bynens (https://mathiasbynens.be/)" ], "repository": "lodash/lodash", "scripts": { "test": "echo \"See https://travis-ci.org/lodash/lodash-cli for testing details.\"" }, "dependencies": { - "lodash._basesortedindexby": "^4.0.0" + "lodash._basesortedindexby": "~4.0.0" } } diff --git a/lodash.sortedindexby/README.md b/lodash.sortedindexby/README.md index bd78ac545..2abd3b007 100644 --- a/lodash.sortedindexby/README.md +++ b/lodash.sortedindexby/README.md @@ -1,4 +1,4 @@ -# lodash.sortedindexby v4.0.1 +# lodash.sortedindexby v4.0.2 The [lodash](https://lodash.com/) method `_.sortedIndexBy` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var sortedIndexBy = require('lodash.sortedindexby'); ``` -See the [documentation](https://lodash.com/docs#sortedIndexBy) or [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash.sortedindexby) for more details. +See the [documentation](https://lodash.com/docs#sortedIndexBy) or [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash.sortedindexby) for more details. diff --git a/lodash.sortedindexby/index.js b/lodash.sortedindexby/index.js index 98340603f..49a0bc891 100644 --- a/lodash.sortedindexby/index.js +++ b/lodash.sortedindexby/index.js @@ -1,5 +1,5 @@ /** - * lodash 4.0.0 (Custom Build) + * lodash 4.0.2 (Custom Build) * Build: `lodash modularize exports="npm" -o ./` * Copyright 2012-2016 The Dojo Foundation * Based on Underscore.js 1.8.3 @@ -41,11 +41,11 @@ var objectProto = global.Object.prototype; var objectToString = objectProto.toString; /** Built-in value references. */ -var _Symbol = global.Symbol; +var Symbol = global.Symbol; /** Used to convert symbols to primitives and strings. */ -var symbolProto = _Symbol ? _Symbol.prototype : undefined, - symbolToString = _Symbol ? symbolProto.toString : undefined; +var symbolProto = Symbol ? Symbol.prototype : undefined, + symbolToString = Symbol ? symbolProto.toString : undefined; /** * The base implementation of `_.get` without support for default values. @@ -308,8 +308,6 @@ var isArray = Array.isArray; * // => false */ function isObject(value) { - // Avoid a V8 JIT bug in Chrome 19-20. - // See https://code.google.com/p/v8/issues/detail?id=2291 for more details. var type = typeof value; return !!value && (type == 'object' || type == 'function'); } @@ -391,7 +389,7 @@ function toString(value) { return ''; } if (isSymbol(value)) { - return _Symbol ? symbolToString.call(value) : ''; + return Symbol ? symbolToString.call(value) : ''; } var result = (value + ''); return (result == '0' && (1 / value) == -INFINITY) ? '-0' : result; diff --git a/lodash.sortedindexby/package.json b/lodash.sortedindexby/package.json index 98ac5ce9c..2d45d010c 100644 --- a/lodash.sortedindexby/package.json +++ b/lodash.sortedindexby/package.json @@ -1,6 +1,6 @@ { "name": "lodash.sortedindexby", - "version": "4.0.1", + "version": "4.0.2", "description": "The lodash method `_.sortedIndexBy` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", diff --git a/lodash.sortedindexof/LICENSE b/lodash.sortedindexof/LICENSE index b054ca5a3..bcbe13d67 100644 --- a/lodash.sortedindexof/LICENSE +++ b/lodash.sortedindexof/LICENSE @@ -1,22 +1,23 @@ +The MIT License (MIT) + Copyright 2012-2016 The Dojo Foundation Based on Underscore.js, copyright 2009-2016 Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors -Permission is hereby granted, free of charge, to any person obtaining -a copy of this software and associated documentation files (the -"Software"), to deal in the Software without restriction, including -without limitation the rights to use, copy, modify, merge, publish, -distribute, sublicense, and/or sell copies of the Software, and to -permit persons to whom the Software is furnished to do so, subject to -the following conditions: +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: -The above copyright notice and this permission notice shall be -included in all copies or substantial portions of the Software. +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, -EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND -NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE -LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION -OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION -WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. diff --git a/lodash.sortedindexof/README.md b/lodash.sortedindexof/README.md index 831123f0f..ce761d83a 100644 --- a/lodash.sortedindexof/README.md +++ b/lodash.sortedindexof/README.md @@ -1,4 +1,4 @@ -# lodash.sortedindexof v4.0.1 +# lodash.sortedindexof v4.0.2 The [lodash](https://lodash.com/) method `_.sortedIndexOf` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var sortedIndexOf = require('lodash.sortedindexof'); ``` -See the [documentation](https://lodash.com/docs#sortedIndexOf) or [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash.sortedindexof) for more details. +See the [documentation](https://lodash.com/docs#sortedIndexOf) or [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash.sortedindexof) for more details. diff --git a/lodash.sortedindexof/index.js b/lodash.sortedindexof/index.js index 1bd7f53b2..5cb961dc6 100644 --- a/lodash.sortedindexof/index.js +++ b/lodash.sortedindexof/index.js @@ -1,5 +1,5 @@ /** - * lodash 4.0.1 (Custom Build) + * lodash 4.0.2 (Custom Build) * Build: `lodash modularize exports="npm" -o ./` * Copyright 2012-2016 The Dojo Foundation * Based on Underscore.js 1.8.3 @@ -50,6 +50,7 @@ function baseSortedIndex(array, value, retHighest) { * * @static * @memberOf _ + * @since 4.0.0 * @category Array * @param {Array} array The array to search. * @param {*} value The value to search for. @@ -71,11 +72,13 @@ function sortedIndexOf(array, value) { } /** - * Performs a [`SameValueZero`](http://ecma-international.org/ecma-262/6.0/#sec-samevaluezero) + * Performs a + * [`SameValueZero`](http://ecma-international.org/ecma-262/6.0/#sec-samevaluezero) * comparison between two values to determine if they are equivalent. * * @static * @memberOf _ + * @since 4.0.0 * @category Lang * @param {*} value The value to compare. * @param {*} other The other value to compare. @@ -108,6 +111,7 @@ function eq(value, other) { * This method returns the first argument given to it. * * @static + * @since 0.1.0 * @memberOf _ * @category Util * @param {*} value Any value. diff --git a/lodash.sortedindexof/package.json b/lodash.sortedindexof/package.json index 3c2c7645c..6c70f7c7e 100644 --- a/lodash.sortedindexof/package.json +++ b/lodash.sortedindexof/package.json @@ -1,20 +1,20 @@ { "name": "lodash.sortedindexof", - "version": "4.0.1", + "version": "4.0.2", "description": "The lodash method `_.sortedIndexOf` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", "license": "MIT", - "keywords": "lodash, lodash-modularized, stdlib, util, sortedindexof", + "keywords": "lodash-modularized, sortedindexof", "author": "John-David Dalton (http://allyoucanleet.com/)", "contributors": [ "John-David Dalton (http://allyoucanleet.com/)", - "Blaine Bublitz (https://github.com/phated)", + "Blaine Bublitz (https://github.com/phated)", "Mathias Bynens (https://mathiasbynens.be/)" ], "repository": "lodash/lodash", "scripts": { "test": "echo \"See https://travis-ci.org/lodash/lodash-cli for testing details.\"" }, "dependencies": { - "lodash._basesortedindexby": "^4.0.0" + "lodash._basesortedindexby": "~4.0.0" } } diff --git a/lodash.sortedlastindex/LICENSE b/lodash.sortedlastindex/LICENSE index b054ca5a3..bcbe13d67 100644 --- a/lodash.sortedlastindex/LICENSE +++ b/lodash.sortedlastindex/LICENSE @@ -1,22 +1,23 @@ +The MIT License (MIT) + Copyright 2012-2016 The Dojo Foundation Based on Underscore.js, copyright 2009-2016 Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors -Permission is hereby granted, free of charge, to any person obtaining -a copy of this software and associated documentation files (the -"Software"), to deal in the Software without restriction, including -without limitation the rights to use, copy, modify, merge, publish, -distribute, sublicense, and/or sell copies of the Software, and to -permit persons to whom the Software is furnished to do so, subject to -the following conditions: +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: -The above copyright notice and this permission notice shall be -included in all copies or substantial portions of the Software. +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, -EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND -NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE -LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION -OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION -WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. diff --git a/lodash.sortedlastindex/README.md b/lodash.sortedlastindex/README.md index 3312e49d2..249dc76e9 100644 --- a/lodash.sortedlastindex/README.md +++ b/lodash.sortedlastindex/README.md @@ -1,4 +1,4 @@ -# lodash.sortedlastindex v4.0.1 +# lodash.sortedlastindex v4.0.2 The [lodash](https://lodash.com/) method `_.sortedLastIndex` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var sortedLastIndex = require('lodash.sortedlastindex'); ``` -See the [documentation](https://lodash.com/docs#sortedLastIndex) or [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash.sortedlastindex) for more details. +See the [documentation](https://lodash.com/docs#sortedLastIndex) or [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash.sortedlastindex) for more details. diff --git a/lodash.sortedlastindex/index.js b/lodash.sortedlastindex/index.js index e80a084f5..f8b324a4f 100644 --- a/lodash.sortedlastindex/index.js +++ b/lodash.sortedlastindex/index.js @@ -1,5 +1,5 @@ /** - * lodash 4.0.1 (Custom Build) + * lodash 4.0.2 (Custom Build) * Build: `lodash modularize exports="npm" -o ./` * Copyright 2012-2016 The Dojo Foundation * Based on Underscore.js 1.8.3 @@ -51,10 +51,12 @@ function baseSortedIndex(array, value, retHighest) { * * @static * @memberOf _ + * @since 3.0.0 * @category Array * @param {Array} array The sorted array to inspect. * @param {*} value The value to evaluate. - * @returns {number} Returns the index at which `value` should be inserted into `array`. + * @returns {number} Returns the index at which `value` should be inserted + * into `array`. * @example * * _.sortedLastIndex([4, 5], 4); @@ -68,6 +70,7 @@ function sortedLastIndex(array, value) { * This method returns the first argument given to it. * * @static + * @since 0.1.0 * @memberOf _ * @category Util * @param {*} value Any value. diff --git a/lodash.sortedlastindex/package.json b/lodash.sortedlastindex/package.json index c56b59bd8..4e811da5b 100644 --- a/lodash.sortedlastindex/package.json +++ b/lodash.sortedlastindex/package.json @@ -1,20 +1,20 @@ { "name": "lodash.sortedlastindex", - "version": "4.0.1", + "version": "4.0.2", "description": "The lodash method `_.sortedLastIndex` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", "license": "MIT", - "keywords": "lodash, lodash-modularized, stdlib, util, sortedlastindex", + "keywords": "lodash-modularized, sortedlastindex", "author": "John-David Dalton (http://allyoucanleet.com/)", "contributors": [ "John-David Dalton (http://allyoucanleet.com/)", - "Blaine Bublitz (https://github.com/phated)", + "Blaine Bublitz (https://github.com/phated)", "Mathias Bynens (https://mathiasbynens.be/)" ], "repository": "lodash/lodash", "scripts": { "test": "echo \"See https://travis-ci.org/lodash/lodash-cli for testing details.\"" }, "dependencies": { - "lodash._basesortedindexby": "^4.0.0" + "lodash._basesortedindexby": "~4.0.0" } } diff --git a/lodash.sortedlastindexby/README.md b/lodash.sortedlastindexby/README.md index 52198d8ab..9620be3bb 100644 --- a/lodash.sortedlastindexby/README.md +++ b/lodash.sortedlastindexby/README.md @@ -1,4 +1,4 @@ -# lodash.sortedlastindexby v4.0.1 +# lodash.sortedlastindexby v4.0.2 The [lodash](https://lodash.com/) method `_.sortedLastIndexBy` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var sortedLastIndexBy = require('lodash.sortedlastindexby'); ``` -See the [documentation](https://lodash.com/docs#sortedLastIndexBy) or [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash.sortedlastindexby) for more details. +See the [documentation](https://lodash.com/docs#sortedLastIndexBy) or [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash.sortedlastindexby) for more details. diff --git a/lodash.sortedlastindexby/index.js b/lodash.sortedlastindexby/index.js index 564cd367b..19bea0f25 100644 --- a/lodash.sortedlastindexby/index.js +++ b/lodash.sortedlastindexby/index.js @@ -1,5 +1,5 @@ /** - * lodash 4.0.0 (Custom Build) + * lodash 4.0.2 (Custom Build) * Build: `lodash modularize exports="npm" -o ./` * Copyright 2012-2016 The Dojo Foundation * Based on Underscore.js 1.8.3 @@ -41,11 +41,11 @@ var objectProto = global.Object.prototype; var objectToString = objectProto.toString; /** Built-in value references. */ -var _Symbol = global.Symbol; +var Symbol = global.Symbol; /** Used to convert symbols to primitives and strings. */ -var symbolProto = _Symbol ? _Symbol.prototype : undefined, - symbolToString = _Symbol ? symbolProto.toString : undefined; +var symbolProto = Symbol ? Symbol.prototype : undefined, + symbolToString = Symbol ? symbolProto.toString : undefined; /** * The base implementation of `_.get` without support for default values. @@ -303,8 +303,6 @@ var isArray = Array.isArray; * // => false */ function isObject(value) { - // Avoid a V8 JIT bug in Chrome 19-20. - // See https://code.google.com/p/v8/issues/detail?id=2291 for more details. var type = typeof value; return !!value && (type == 'object' || type == 'function'); } @@ -386,7 +384,7 @@ function toString(value) { return ''; } if (isSymbol(value)) { - return _Symbol ? symbolToString.call(value) : ''; + return Symbol ? symbolToString.call(value) : ''; } var result = (value + ''); return (result == '0' && (1 / value) == -INFINITY) ? '-0' : result; diff --git a/lodash.sortedlastindexby/package.json b/lodash.sortedlastindexby/package.json index 9f7906f42..438143049 100644 --- a/lodash.sortedlastindexby/package.json +++ b/lodash.sortedlastindexby/package.json @@ -1,6 +1,6 @@ { "name": "lodash.sortedlastindexby", - "version": "4.0.1", + "version": "4.0.2", "description": "The lodash method `_.sortedLastIndexBy` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", diff --git a/lodash.sortedlastindexof/LICENSE b/lodash.sortedlastindexof/LICENSE index b054ca5a3..bcbe13d67 100644 --- a/lodash.sortedlastindexof/LICENSE +++ b/lodash.sortedlastindexof/LICENSE @@ -1,22 +1,23 @@ +The MIT License (MIT) + Copyright 2012-2016 The Dojo Foundation Based on Underscore.js, copyright 2009-2016 Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors -Permission is hereby granted, free of charge, to any person obtaining -a copy of this software and associated documentation files (the -"Software"), to deal in the Software without restriction, including -without limitation the rights to use, copy, modify, merge, publish, -distribute, sublicense, and/or sell copies of the Software, and to -permit persons to whom the Software is furnished to do so, subject to -the following conditions: +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: -The above copyright notice and this permission notice shall be -included in all copies or substantial portions of the Software. +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, -EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND -NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE -LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION -OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION -WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. diff --git a/lodash.sortedlastindexof/README.md b/lodash.sortedlastindexof/README.md index b63929858..c0c877726 100644 --- a/lodash.sortedlastindexof/README.md +++ b/lodash.sortedlastindexof/README.md @@ -1,4 +1,4 @@ -# lodash.sortedlastindexof v4.0.1 +# lodash.sortedlastindexof v4.0.2 The [lodash](https://lodash.com/) method `_.sortedLastIndexOf` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var sortedLastIndexOf = require('lodash.sortedlastindexof'); ``` -See the [documentation](https://lodash.com/docs#sortedLastIndexOf) or [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash.sortedlastindexof) for more details. +See the [documentation](https://lodash.com/docs#sortedLastIndexOf) or [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash.sortedlastindexof) for more details. diff --git a/lodash.sortedlastindexof/index.js b/lodash.sortedlastindexof/index.js index d0a3949bf..35f539f8a 100644 --- a/lodash.sortedlastindexof/index.js +++ b/lodash.sortedlastindexof/index.js @@ -1,5 +1,5 @@ /** - * lodash 4.0.1 (Custom Build) + * lodash 4.0.2 (Custom Build) * Build: `lodash modularize exports="npm" -o ./` * Copyright 2012-2016 The Dojo Foundation * Based on Underscore.js 1.8.3 @@ -50,6 +50,7 @@ function baseSortedIndex(array, value, retHighest) { * * @static * @memberOf _ + * @since 4.0.0 * @category Array * @param {Array} array The array to search. * @param {*} value The value to search for. @@ -71,11 +72,13 @@ function sortedLastIndexOf(array, value) { } /** - * Performs a [`SameValueZero`](http://ecma-international.org/ecma-262/6.0/#sec-samevaluezero) + * Performs a + * [`SameValueZero`](http://ecma-international.org/ecma-262/6.0/#sec-samevaluezero) * comparison between two values to determine if they are equivalent. * * @static * @memberOf _ + * @since 4.0.0 * @category Lang * @param {*} value The value to compare. * @param {*} other The other value to compare. @@ -108,6 +111,7 @@ function eq(value, other) { * This method returns the first argument given to it. * * @static + * @since 0.1.0 * @memberOf _ * @category Util * @param {*} value Any value. diff --git a/lodash.sortedlastindexof/package.json b/lodash.sortedlastindexof/package.json index 8fe34aa8a..27766083f 100644 --- a/lodash.sortedlastindexof/package.json +++ b/lodash.sortedlastindexof/package.json @@ -1,20 +1,20 @@ { "name": "lodash.sortedlastindexof", - "version": "4.0.1", + "version": "4.0.2", "description": "The lodash method `_.sortedLastIndexOf` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", "license": "MIT", - "keywords": "lodash, lodash-modularized, stdlib, util, sortedlastindexof", + "keywords": "lodash-modularized, sortedlastindexof", "author": "John-David Dalton (http://allyoucanleet.com/)", "contributors": [ "John-David Dalton (http://allyoucanleet.com/)", - "Blaine Bublitz (https://github.com/phated)", + "Blaine Bublitz (https://github.com/phated)", "Mathias Bynens (https://mathiasbynens.be/)" ], "repository": "lodash/lodash", "scripts": { "test": "echo \"See https://travis-ci.org/lodash/lodash-cli for testing details.\"" }, "dependencies": { - "lodash._basesortedindexby": "^4.0.0" + "lodash._basesortedindexby": "~4.0.0" } } diff --git a/lodash.sorteduniq/LICENSE b/lodash.sorteduniq/LICENSE index b054ca5a3..bcbe13d67 100644 --- a/lodash.sorteduniq/LICENSE +++ b/lodash.sorteduniq/LICENSE @@ -1,22 +1,23 @@ +The MIT License (MIT) + Copyright 2012-2016 The Dojo Foundation Based on Underscore.js, copyright 2009-2016 Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors -Permission is hereby granted, free of charge, to any person obtaining -a copy of this software and associated documentation files (the -"Software"), to deal in the Software without restriction, including -without limitation the rights to use, copy, modify, merge, publish, -distribute, sublicense, and/or sell copies of the Software, and to -permit persons to whom the Software is furnished to do so, subject to -the following conditions: +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: -The above copyright notice and this permission notice shall be -included in all copies or substantial portions of the Software. +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, -EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND -NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE -LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION -OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION -WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. diff --git a/lodash.sorteduniq/README.md b/lodash.sorteduniq/README.md index 2096d5581..b913bb939 100644 --- a/lodash.sorteduniq/README.md +++ b/lodash.sorteduniq/README.md @@ -1,4 +1,4 @@ -# lodash.sorteduniq v4.0.1 +# lodash.sorteduniq v4.0.2 The [lodash](https://lodash.com/) method `_.sortedUniq` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var sortedUniq = require('lodash.sorteduniq'); ``` -See the [documentation](https://lodash.com/docs#sortedUniq) or [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash.sorteduniq) for more details. +See the [documentation](https://lodash.com/docs#sortedUniq) or [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash.sorteduniq) for more details. diff --git a/lodash.sorteduniq/index.js b/lodash.sorteduniq/index.js index e3fd9fa38..24bc9f806 100644 --- a/lodash.sorteduniq/index.js +++ b/lodash.sorteduniq/index.js @@ -1,5 +1,5 @@ /** - * lodash 4.0.0 (Custom Build) + * lodash 4.0.2 (Custom Build) * Build: `lodash modularize exports="npm" -o ./` * Copyright 2012-2016 The Dojo Foundation * Based on Underscore.js 1.8.3 @@ -25,6 +25,7 @@ function baseSortedUniq(array) { * * @static * @memberOf _ + * @since 4.0.0 * @category Array * @param {Array} array The array to inspect. * @returns {Array} Returns the new duplicate free array. diff --git a/lodash.sorteduniq/package.json b/lodash.sorteduniq/package.json index 775b11ff5..9dc048ec7 100644 --- a/lodash.sorteduniq/package.json +++ b/lodash.sorteduniq/package.json @@ -1,20 +1,20 @@ { "name": "lodash.sorteduniq", - "version": "4.0.1", + "version": "4.0.2", "description": "The lodash method `_.sortedUniq` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", "license": "MIT", - "keywords": "lodash, lodash-modularized, stdlib, util, sorteduniq", + "keywords": "lodash-modularized, sorteduniq", "author": "John-David Dalton (http://allyoucanleet.com/)", "contributors": [ "John-David Dalton (http://allyoucanleet.com/)", - "Blaine Bublitz (https://github.com/phated)", + "Blaine Bublitz (https://github.com/phated)", "Mathias Bynens (https://mathiasbynens.be/)" ], "repository": "lodash/lodash", "scripts": { "test": "echo \"See https://travis-ci.org/lodash/lodash-cli for testing details.\"" }, "dependencies": { - "lodash._basesorteduniqby": "^4.0.0" + "lodash._basesorteduniqby": "~4.0.0" } } diff --git a/lodash.sorteduniqby/README.md b/lodash.sorteduniqby/README.md index 3e51ba9e9..16cc7b17c 100644 --- a/lodash.sorteduniqby/README.md +++ b/lodash.sorteduniqby/README.md @@ -1,4 +1,4 @@ -# lodash.sorteduniqby v4.0.1 +# lodash.sorteduniqby v4.0.2 The [lodash](https://lodash.com/) method `_.sortedUniqBy` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var sortedUniqBy = require('lodash.sorteduniqby'); ``` -See the [documentation](https://lodash.com/docs#sortedUniqBy) or [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash.sorteduniqby) for more details. +See the [documentation](https://lodash.com/docs#sortedUniqBy) or [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash.sorteduniqby) for more details. diff --git a/lodash.sorteduniqby/index.js b/lodash.sorteduniqby/index.js index 2f03b6616..0bf732b20 100644 --- a/lodash.sorteduniqby/index.js +++ b/lodash.sorteduniqby/index.js @@ -1,5 +1,5 @@ /** - * lodash 4.0.0 (Custom Build) + * lodash 4.0.2 (Custom Build) * Build: `lodash modularize exports="npm" -o ./` * Copyright 2012-2016 The Dojo Foundation * Based on Underscore.js 1.8.3 @@ -41,11 +41,11 @@ var objectProto = global.Object.prototype; var objectToString = objectProto.toString; /** Built-in value references. */ -var _Symbol = global.Symbol; +var Symbol = global.Symbol; /** Used to convert symbols to primitives and strings. */ -var symbolProto = _Symbol ? _Symbol.prototype : undefined, - symbolToString = _Symbol ? symbolProto.toString : undefined; +var symbolProto = Symbol ? Symbol.prototype : undefined, + symbolToString = Symbol ? symbolProto.toString : undefined; /** * The base implementation of `_.get` without support for default values. @@ -302,8 +302,6 @@ var isArray = Array.isArray; * // => false */ function isObject(value) { - // Avoid a V8 JIT bug in Chrome 19-20. - // See https://code.google.com/p/v8/issues/detail?id=2291 for more details. var type = typeof value; return !!value && (type == 'object' || type == 'function'); } @@ -385,7 +383,7 @@ function toString(value) { return ''; } if (isSymbol(value)) { - return _Symbol ? symbolToString.call(value) : ''; + return Symbol ? symbolToString.call(value) : ''; } var result = (value + ''); return (result == '0' && (1 / value) == -INFINITY) ? '-0' : result; diff --git a/lodash.sorteduniqby/package.json b/lodash.sorteduniqby/package.json index 113a2bf68..a2c7f2d9f 100644 --- a/lodash.sorteduniqby/package.json +++ b/lodash.sorteduniqby/package.json @@ -1,6 +1,6 @@ { "name": "lodash.sorteduniqby", - "version": "4.0.1", + "version": "4.0.2", "description": "The lodash method `_.sortedUniqBy` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", diff --git a/lodash.split/README.md b/lodash.split/README.md index bbf2e1000..b0755f876 100644 --- a/lodash.split/README.md +++ b/lodash.split/README.md @@ -1,4 +1,4 @@ -# lodash.split v4.0.1 +# lodash.split v4.0.2 The [lodash](https://lodash.com/) method `_.split` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var split = require('lodash.split'); ``` -See the [documentation](https://lodash.com/docs#split) or [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash.split) for more details. +See the [documentation](https://lodash.com/docs#split) or [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash.split) for more details. diff --git a/lodash.split/index.js b/lodash.split/index.js index 79cc3c758..c46055d55 100644 --- a/lodash.split/index.js +++ b/lodash.split/index.js @@ -1,5 +1,5 @@ /** - * lodash 4.0.1 (Custom Build) + * lodash 4.0.2 (Custom Build) * Build: `lodash modularize exports="npm" -o ./` * Copyright 2012-2016 The Dojo Foundation * Based on Underscore.js 1.8.3 @@ -13,8 +13,51 @@ var INFINITY = 1 / 0; /** `Object#toString` result references. */ var symbolTag = '[object Symbol]'; +/** Used to determine if values are of the language type `Object`. */ +var objectTypes = { + 'function': true, + 'object': true +}; + +/** Detect free variable `exports`. */ +var freeExports = (objectTypes[typeof exports] && exports && !exports.nodeType) ? exports : null; + +/** Detect free variable `module`. */ +var freeModule = (objectTypes[typeof module] && module && !module.nodeType) ? module : null; + +/** Detect free variable `global` from Node.js. */ +var freeGlobal = checkGlobal(freeExports && freeModule && typeof global == 'object' && global); + +/** Detect free variable `self`. */ +var freeSelf = checkGlobal(objectTypes[typeof self] && self); + +/** Detect free variable `window`. */ +var freeWindow = checkGlobal(objectTypes[typeof window] && window); + +/** Detect `this` as the global object. */ +var thisGlobal = checkGlobal(objectTypes[typeof this] && this); + +/** + * Used as a reference to the global object. + * + * The `this` value is used if it's the global object to avoid Greasemonkey's + * restricted `window` object, otherwise the `window` object is used. + */ +var root = freeGlobal || ((freeWindow !== (thisGlobal && thisGlobal.window)) && freeWindow) || freeSelf || thisGlobal || Function('return this')(); + +/** + * Checks if `value` is a global object. + * + * @private + * @param {*} value The value to check. + * @returns {null|Object} Returns `value` if it's a global object, else `null`. + */ +function checkGlobal(value) { + return (value && value.Object === Object) ? value : null; +} + /** Used for built-in method references. */ -var objectProto = global.Object.prototype; +var objectProto = Object.prototype; /** * Used to resolve the [`toStringTag`](http://ecma-international.org/ecma-262/6.0/#sec-object.prototype.tostring) @@ -23,7 +66,7 @@ var objectProto = global.Object.prototype; var objectToString = objectProto.toString; /** Built-in value references. */ -var Symbol = global.Symbol; +var Symbol = root.Symbol; /** Used to convert symbols to primitives and strings. */ var symbolProto = Symbol ? Symbol.prototype : undefined, diff --git a/lodash.split/package.json b/lodash.split/package.json index 08c5df0ae..382759e2f 100644 --- a/lodash.split/package.json +++ b/lodash.split/package.json @@ -1,11 +1,11 @@ { "name": "lodash.split", - "version": "4.0.1", + "version": "4.0.2", "description": "The lodash method `_.split` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", "license": "MIT", - "keywords": "lodash, lodash-modularized, stdlib, util, split", + "keywords": "lodash-modularized, split", "author": "John-David Dalton (http://allyoucanleet.com/)", "contributors": [ "John-David Dalton (http://allyoucanleet.com/)", diff --git a/lodash.subtract/LICENSE b/lodash.subtract/LICENSE index bcbe13d67..e0c69d560 100644 --- a/lodash.subtract/LICENSE +++ b/lodash.subtract/LICENSE @@ -1,23 +1,47 @@ -The MIT License (MIT) +Copyright jQuery Foundation and other contributors -Copyright 2012-2016 The Dojo Foundation -Based on Underscore.js, copyright 2009-2016 Jeremy Ashkenas, +Based on Underscore.js, copyright Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors -Permission is hereby granted, free of charge, to any person obtaining a copy -of this software and associated documentation files (the "Software"), to deal -in the Software without restriction, including without limitation the rights -to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the Software, and to permit persons to whom the Software is -furnished to do so, subject to the following conditions: +This software consists of voluntary contributions made by many +individuals. For exact contribution history, see the revision history +available at https://github.com/lodash/lodash -The above copyright notice and this permission notice shall be included in all -copies or substantial portions of the Software. +The following license applies to all parts of this software except as +documented below: -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE -SOFTWARE. +==== + +Permission is hereby granted, free of charge, to any person obtaining +a copy of this software and associated documentation files (the +"Software"), to deal in the Software without restriction, including +without limitation the rights to use, copy, modify, merge, publish, +distribute, sublicense, and/or sell copies of the Software, and to +permit persons to whom the Software is furnished to do so, subject to +the following conditions: + +The above copyright notice and this permission notice shall be +included in all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, +EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF +MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND +NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE +LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION +OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION +WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + +==== + +Copyright and related rights for sample code are waived via CC0. Sample +code is defined as all source code displayed within the prose of the +documentation. + +CC0: http://creativecommons.org/publicdomain/zero/1.0/ + +==== + +Files located in the node_modules and vendor directories are externally +maintained libraries used by this software which have their own +licenses; we recommend you read them, as their terms may differ from the +terms above. diff --git a/lodash.subtract/README.md b/lodash.subtract/README.md index ef99e9c0c..9de50aaec 100644 --- a/lodash.subtract/README.md +++ b/lodash.subtract/README.md @@ -1,4 +1,4 @@ -# lodash.subtract v4.0.1 +# lodash.subtract v4.0.2 The [lodash](https://lodash.com/) method `_.subtract` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var subtract = require('lodash.subtract'); ``` -See the [documentation](https://lodash.com/docs#subtract) or [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash.subtract) for more details. +See the [documentation](https://lodash.com/docs#subtract) or [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash.subtract) for more details. diff --git a/lodash.subtract/index.js b/lodash.subtract/index.js index dba620733..9e205183a 100644 --- a/lodash.subtract/index.js +++ b/lodash.subtract/index.js @@ -1,17 +1,41 @@ /** - * lodash 4.0.1 (Custom Build) + * lodash 4.0.2 (Custom Build) * Build: `lodash modularize exports="npm" -o ./` - * Copyright 2012-2016 The Dojo Foundation + * Copyright jQuery Foundation and other contributors + * Released under MIT license * Based on Underscore.js 1.8.3 - * Copyright 2009-2016 Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors - * Available under MIT license + * Copyright Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors */ +/** + * Creates a function that performs a mathematical operation on two values. + * + * @private + * @param {Function} operator The function to perform the operation. + * @returns {Function} Returns the new mathematical operation function. + */ +function createMathOperation(operator) { + return function(value, other) { + var result; + if (value === undefined && other === undefined) { + return 0; + } + if (value !== undefined) { + result = value; + } + if (other !== undefined) { + result = result === undefined ? other : operator(result, other); + } + return result; + }; +} + /** * Subtract two numbers. * * @static * @memberOf _ + * @since 4.0.0 * @category Math * @param {number} minuend The first number in a subtraction. * @param {number} subtrahend The second number in a subtraction. @@ -21,18 +45,8 @@ * _.subtract(6, 4); * // => 2 */ -function subtract(minuend, subtrahend) { - var result; - if (minuend === undefined && subtrahend === undefined) { - return 0; - } - if (minuend !== undefined) { - result = minuend; - } - if (subtrahend !== undefined) { - result = result === undefined ? subtrahend : (result - subtrahend); - } - return result; -} +var subtract = createMathOperation(function(minuend, subtrahend) { + return minuend - subtrahend; +}); module.exports = subtract; diff --git a/lodash.subtract/package.json b/lodash.subtract/package.json index 860157601..0fba658d3 100644 --- a/lodash.subtract/package.json +++ b/lodash.subtract/package.json @@ -1,6 +1,6 @@ { "name": "lodash.subtract", - "version": "4.0.1", + "version": "4.0.2", "description": "The lodash method `_.subtract` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", @@ -9,7 +9,7 @@ "author": "John-David Dalton (http://allyoucanleet.com/)", "contributors": [ "John-David Dalton (http://allyoucanleet.com/)", - "Blaine Bublitz (https://github.com/phated)", + "Blaine Bublitz (https://github.com/phated)", "Mathias Bynens (https://mathiasbynens.be/)" ], "repository": "lodash/lodash", diff --git a/lodash.sum/README.md b/lodash.sum/README.md index 85ac1f427..f22c0b7f6 100644 --- a/lodash.sum/README.md +++ b/lodash.sum/README.md @@ -1,4 +1,4 @@ -# lodash.sum v4.0.1 +# lodash.sum v4.0.2 The [lodash](https://lodash.com/) method `_.sum` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var sum = require('lodash.sum'); ``` -See the [documentation](https://lodash.com/docs#sum) or [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash.sum) for more details. +See the [documentation](https://lodash.com/docs#sum) or [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash.sum) for more details. diff --git a/lodash.sum/index.js b/lodash.sum/index.js index ffa487c25..d39993ae8 100644 --- a/lodash.sum/index.js +++ b/lodash.sum/index.js @@ -1,5 +1,5 @@ /** - * lodash 4.0.1 (Custom Build) + * lodash (Custom Build) * Build: `lodash modularize exports="npm" -o ./` * Copyright 2012-2016 The Dojo Foundation * Based on Underscore.js 1.8.3 @@ -8,7 +8,8 @@ */ /** - * The base implementation of `_.sum` without support for iteratee shorthands. + * The base implementation of `_.sum` and `_.sumBy` without support for + * iteratee shorthands. * * @private * @param {Array} array The array to iterate over. @@ -26,22 +27,23 @@ function baseSum(array, iteratee) { result = result === undefined ? current : (result + current); } } - return length ? result : 0; + return result; } /** - * This method returns the first argument provided to it. + * This method returns the first argument it receives. * * @static + * @since 0.1.0 * @memberOf _ * @category Util * @param {*} value Any value. * @returns {*} Returns `value`. * @example * - * var object = { 'user': 'fred' }; + * var object = { 'a': 1 }; * - * _.identity(object) === object; + * console.log(_.identity(object) === object); * // => true */ function identity(value) { @@ -53,6 +55,7 @@ function identity(value) { * * @static * @memberOf _ + * @since 3.4.0 * @category Math * @param {Array} array The array to iterate over. * @returns {number} Returns the sum. diff --git a/lodash.sum/package.json b/lodash.sum/package.json index 6d023d4e0..6e71df07b 100644 --- a/lodash.sum/package.json +++ b/lodash.sum/package.json @@ -1,6 +1,6 @@ { "name": "lodash.sum", - "version": "4.0.1", + "version": "4.0.2", "description": "The lodash method `_.sum` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", diff --git a/lodash.sumby/README.md b/lodash.sumby/README.md index a4306390b..92364c3ac 100644 --- a/lodash.sumby/README.md +++ b/lodash.sumby/README.md @@ -1,4 +1,4 @@ -# lodash.sumby v4.0.1 +# lodash.sumby v4.0.2 The [lodash](https://lodash.com/) method `_.sumBy` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var sumBy = require('lodash.sumby'); ``` -See the [documentation](https://lodash.com/docs#sumBy) or [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash.sumby) for more details. +See the [documentation](https://lodash.com/docs#sumBy) or [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash.sumby) for more details. diff --git a/lodash.sumby/index.js b/lodash.sumby/index.js index 27209328f..570615b57 100644 --- a/lodash.sumby/index.js +++ b/lodash.sumby/index.js @@ -1,5 +1,5 @@ /** - * lodash 4.0.1 (Custom Build) + * lodash 4.0.2 (Custom Build) * Build: `lodash modularize exports="npm" -o ./` * Copyright 2012-2016 The Dojo Foundation * Based on Underscore.js 1.8.3 @@ -49,7 +49,7 @@ function baseSum(array, iteratee) { result = result === undefined ? current : (result + current); } } - return result; + return length ? result : 0; } /** Used for built-in method references. */ @@ -302,8 +302,6 @@ var isArray = Array.isArray; * // => false */ function isObject(value) { - // Avoid a V8 JIT bug in Chrome 19-20. - // See https://code.google.com/p/v8/issues/detail?id=2291 for more details. var type = typeof value; return !!value && (type == 'object' || type == 'function'); } @@ -460,7 +458,7 @@ function property(path) { function sumBy(array, iteratee) { return (array && array.length) ? baseSum(array, baseIteratee(iteratee)) - : undefined; + : 0; } module.exports = sumBy; diff --git a/lodash.sumby/package.json b/lodash.sumby/package.json index 6eba5ea57..5aec93cee 100644 --- a/lodash.sumby/package.json +++ b/lodash.sumby/package.json @@ -1,11 +1,11 @@ { "name": "lodash.sumby", - "version": "4.0.1", + "version": "4.0.2", "description": "The lodash method `_.sumBy` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", "license": "MIT", - "keywords": "lodash, lodash-modularized, stdlib, util, sumby", + "keywords": "lodash-modularized, sumby", "author": "John-David Dalton (http://allyoucanleet.com/)", "contributors": [ "John-David Dalton (http://allyoucanleet.com/)", diff --git a/lodash.tail/LICENSE b/lodash.tail/LICENSE index b054ca5a3..bcbe13d67 100644 --- a/lodash.tail/LICENSE +++ b/lodash.tail/LICENSE @@ -1,22 +1,23 @@ +The MIT License (MIT) + Copyright 2012-2016 The Dojo Foundation Based on Underscore.js, copyright 2009-2016 Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors -Permission is hereby granted, free of charge, to any person obtaining -a copy of this software and associated documentation files (the -"Software"), to deal in the Software without restriction, including -without limitation the rights to use, copy, modify, merge, publish, -distribute, sublicense, and/or sell copies of the Software, and to -permit persons to whom the Software is furnished to do so, subject to -the following conditions: +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: -The above copyright notice and this permission notice shall be -included in all copies or substantial portions of the Software. +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, -EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND -NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE -LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION -OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION -WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. diff --git a/lodash.tail/README.md b/lodash.tail/README.md index d81077832..fb3312169 100644 --- a/lodash.tail/README.md +++ b/lodash.tail/README.md @@ -1,4 +1,4 @@ -# lodash.tail v4.0.1 +# lodash.tail v4.0.2 The [lodash](https://lodash.com/) method `_.tail` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var tail = require('lodash.tail'); ``` -See the [documentation](https://lodash.com/docs#tail) or [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash.tail) for more details. +See the [documentation](https://lodash.com/docs#tail) or [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash.tail) for more details. diff --git a/lodash.tail/index.js b/lodash.tail/index.js index 72c061ca3..7be4ba190 100644 --- a/lodash.tail/index.js +++ b/lodash.tail/index.js @@ -1,5 +1,5 @@ /** - * lodash 4.0.1 (Custom Build) + * lodash 4.0.2 (Custom Build) * Build: `lodash modularize exports="npm" -o ./` * Copyright 2012-2016 The Dojo Foundation * Based on Underscore.js 1.8.3 diff --git a/lodash.tail/package.json b/lodash.tail/package.json index 5855ff2e5..17c42d97f 100644 --- a/lodash.tail/package.json +++ b/lodash.tail/package.json @@ -1,6 +1,6 @@ { "name": "lodash.tail", - "version": "4.0.1", + "version": "4.0.2", "description": "The lodash method `_.tail` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", @@ -9,12 +9,12 @@ "author": "John-David Dalton (http://allyoucanleet.com/)", "contributors": [ "John-David Dalton (http://allyoucanleet.com/)", - "Blaine Bublitz (https://github.com/phated)", + "Blaine Bublitz (https://github.com/phated)", "Mathias Bynens (https://mathiasbynens.be/)" ], "repository": "lodash/lodash", "scripts": { "test": "echo \"See https://travis-ci.org/lodash/lodash-cli for testing details.\"" }, "dependencies": { - "lodash._baseslice": "^4.0.0" + "lodash._baseslice": "~4.0.0" } } diff --git a/lodash.take/LICENSE b/lodash.take/LICENSE index b054ca5a3..bcbe13d67 100644 --- a/lodash.take/LICENSE +++ b/lodash.take/LICENSE @@ -1,22 +1,23 @@ +The MIT License (MIT) + Copyright 2012-2016 The Dojo Foundation Based on Underscore.js, copyright 2009-2016 Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors -Permission is hereby granted, free of charge, to any person obtaining -a copy of this software and associated documentation files (the -"Software"), to deal in the Software without restriction, including -without limitation the rights to use, copy, modify, merge, publish, -distribute, sublicense, and/or sell copies of the Software, and to -permit persons to whom the Software is furnished to do so, subject to -the following conditions: +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: -The above copyright notice and this permission notice shall be -included in all copies or substantial portions of the Software. +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, -EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND -NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE -LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION -OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION -WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. diff --git a/lodash.take/README.md b/lodash.take/README.md index 3f507e3f5..c3052e5b6 100644 --- a/lodash.take/README.md +++ b/lodash.take/README.md @@ -1,4 +1,4 @@ -# lodash.take v4.0.1 +# lodash.take v4.0.2 The [lodash](https://lodash.com/) method `_.take` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var take = require('lodash.take'); ``` -See the [documentation](https://lodash.com/docs#take) or [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash.take) for more details. +See the [documentation](https://lodash.com/docs#take) or [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash.take) for more details. diff --git a/lodash.take/index.js b/lodash.take/index.js index 80403fbc5..cd571f569 100644 --- a/lodash.take/index.js +++ b/lodash.take/index.js @@ -1,5 +1,5 @@ /** - * lodash 4.0.1 (Custom Build) + * lodash 4.0.2 (Custom Build) * Build: `lodash modularize exports="npm" -o ./` * Copyright 2012-2016 The Dojo Foundation * Based on Underscore.js 1.8.3 diff --git a/lodash.take/package.json b/lodash.take/package.json index b838f6515..00425891a 100644 --- a/lodash.take/package.json +++ b/lodash.take/package.json @@ -1,6 +1,6 @@ { "name": "lodash.take", - "version": "4.0.1", + "version": "4.0.2", "description": "The lodash method `_.take` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", @@ -9,12 +9,12 @@ "author": "John-David Dalton (http://allyoucanleet.com/)", "contributors": [ "John-David Dalton (http://allyoucanleet.com/)", - "Blaine Bublitz (https://github.com/phated)", + "Blaine Bublitz (https://github.com/phated)", "Mathias Bynens (https://mathiasbynens.be/)" ], "repository": "lodash/lodash", "scripts": { "test": "echo \"See https://travis-ci.org/lodash/lodash-cli for testing details.\"" }, "dependencies": { - "lodash._baseslice": "^4.0.0" + "lodash._baseslice": "~4.0.0" } } diff --git a/lodash.takeright/LICENSE b/lodash.takeright/LICENSE index b054ca5a3..bcbe13d67 100644 --- a/lodash.takeright/LICENSE +++ b/lodash.takeright/LICENSE @@ -1,22 +1,23 @@ +The MIT License (MIT) + Copyright 2012-2016 The Dojo Foundation Based on Underscore.js, copyright 2009-2016 Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors -Permission is hereby granted, free of charge, to any person obtaining -a copy of this software and associated documentation files (the -"Software"), to deal in the Software without restriction, including -without limitation the rights to use, copy, modify, merge, publish, -distribute, sublicense, and/or sell copies of the Software, and to -permit persons to whom the Software is furnished to do so, subject to -the following conditions: +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: -The above copyright notice and this permission notice shall be -included in all copies or substantial portions of the Software. +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, -EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND -NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE -LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION -OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION -WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. diff --git a/lodash.takeright/README.md b/lodash.takeright/README.md index d1fc7cec0..a51ce2cf0 100644 --- a/lodash.takeright/README.md +++ b/lodash.takeright/README.md @@ -1,4 +1,4 @@ -# lodash.takeright v4.0.1 +# lodash.takeright v4.0.2 The [lodash](https://lodash.com/) method `_.takeRight` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var takeRight = require('lodash.takeright'); ``` -See the [documentation](https://lodash.com/docs#takeRight) or [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash.takeright) for more details. +See the [documentation](https://lodash.com/docs#takeRight) or [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash.takeright) for more details. diff --git a/lodash.takeright/index.js b/lodash.takeright/index.js index 5dc56bae2..af2be0eab 100644 --- a/lodash.takeright/index.js +++ b/lodash.takeright/index.js @@ -1,5 +1,5 @@ /** - * lodash 4.0.1 (Custom Build) + * lodash 4.0.2 (Custom Build) * Build: `lodash modularize exports="npm" -o ./` * Copyright 2012-2016 The Dojo Foundation * Based on Underscore.js 1.8.3 diff --git a/lodash.takeright/package.json b/lodash.takeright/package.json index 6d8640db7..b9ae8d097 100644 --- a/lodash.takeright/package.json +++ b/lodash.takeright/package.json @@ -1,6 +1,6 @@ { "name": "lodash.takeright", - "version": "4.0.1", + "version": "4.0.2", "description": "The lodash method `_.takeRight` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", @@ -9,12 +9,12 @@ "author": "John-David Dalton (http://allyoucanleet.com/)", "contributors": [ "John-David Dalton (http://allyoucanleet.com/)", - "Blaine Bublitz (https://github.com/phated)", + "Blaine Bublitz (https://github.com/phated)", "Mathias Bynens (https://mathiasbynens.be/)" ], "repository": "lodash/lodash", "scripts": { "test": "echo \"See https://travis-ci.org/lodash/lodash-cli for testing details.\"" }, "dependencies": { - "lodash._baseslice": "^4.0.0" + "lodash._baseslice": "~4.0.0" } } diff --git a/lodash.takerightwhile/README.md b/lodash.takerightwhile/README.md index 768fe9744..58a02b266 100644 --- a/lodash.takerightwhile/README.md +++ b/lodash.takerightwhile/README.md @@ -1,4 +1,4 @@ -# lodash.takerightwhile v4.0.1 +# lodash.takerightwhile v4.0.2 The [lodash](https://lodash.com/) method `_.takeRightWhile` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var takeRightWhile = require('lodash.takerightwhile'); ``` -See the [documentation](https://lodash.com/docs#takeRightWhile) or [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash.takerightwhile) for more details. +See the [documentation](https://lodash.com/docs#takeRightWhile) or [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash.takerightwhile) for more details. diff --git a/lodash.takerightwhile/index.js b/lodash.takerightwhile/index.js index 69f630ab9..3853e9043 100644 --- a/lodash.takerightwhile/index.js +++ b/lodash.takerightwhile/index.js @@ -1,5 +1,5 @@ /** - * lodash 4.0.1 (Custom Build) + * lodash 4.0.2 (Custom Build) * Build: `lodash modularize exports="npm" -o ./` * Copyright 2012-2016 The Dojo Foundation * Based on Underscore.js 1.8.3 @@ -31,8 +31,51 @@ var reIsDeepProp = /\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/, /** Used to match backslashes in property paths. */ var reEscapeChar = /\\(\\)?/g; +/** Used to determine if values are of the language type `Object`. */ +var objectTypes = { + 'function': true, + 'object': true +}; + +/** Detect free variable `exports`. */ +var freeExports = (objectTypes[typeof exports] && exports && !exports.nodeType) ? exports : null; + +/** Detect free variable `module`. */ +var freeModule = (objectTypes[typeof module] && module && !module.nodeType) ? module : null; + +/** Detect free variable `global` from Node.js. */ +var freeGlobal = checkGlobal(freeExports && freeModule && typeof global == 'object' && global); + +/** Detect free variable `self`. */ +var freeSelf = checkGlobal(objectTypes[typeof self] && self); + +/** Detect free variable `window`. */ +var freeWindow = checkGlobal(objectTypes[typeof window] && window); + +/** Detect `this` as the global object. */ +var thisGlobal = checkGlobal(objectTypes[typeof this] && this); + +/** + * Used as a reference to the global object. + * + * The `this` value is used if it's the global object to avoid Greasemonkey's + * restricted `window` object, otherwise the `window` object is used. + */ +var root = freeGlobal || ((freeWindow !== (thisGlobal && thisGlobal.window)) && freeWindow) || freeSelf || thisGlobal || Function('return this')(); + +/** + * Checks if `value` is a global object. + * + * @private + * @param {*} value The value to check. + * @returns {null|Object} Returns `value` if it's a global object, else `null`. + */ +function checkGlobal(value) { + return (value && value.Object === Object) ? value : null; +} + /** Used for built-in method references. */ -var objectProto = global.Object.prototype; +var objectProto = Object.prototype; /** * Used to resolve the [`toStringTag`](http://ecma-international.org/ecma-262/6.0/#sec-object.prototype.tostring) @@ -41,7 +84,7 @@ var objectProto = global.Object.prototype; var objectToString = objectProto.toString; /** Built-in value references. */ -var Symbol = global.Symbol; +var Symbol = root.Symbol; /** Used to convert symbols to primitives and strings. */ var symbolProto = Symbol ? Symbol.prototype : undefined, @@ -277,15 +320,15 @@ function stringToPath(string) { * _.takeRightWhile(users, function(o) { return !o.active; }); * // => objects for ['fred', 'pebbles'] * - * // using the `_.matches` iteratee shorthand + * // The `_.matches` iteratee shorthand. * _.takeRightWhile(users, { 'user': 'pebbles', 'active': false }); * // => objects for ['pebbles'] * - * // using the `_.matchesProperty` iteratee shorthand + * // The `_.matchesProperty` iteratee shorthand. * _.takeRightWhile(users, ['active', false]); * // => objects for ['fred', 'pebbles'] * - * // using the `_.property` iteratee shorthand + * // The `_.property` iteratee shorthand. * _.takeRightWhile(users, 'active'); * // => [] */ diff --git a/lodash.takerightwhile/package.json b/lodash.takerightwhile/package.json index 1db8d266e..f6c3ed272 100644 --- a/lodash.takerightwhile/package.json +++ b/lodash.takerightwhile/package.json @@ -1,11 +1,11 @@ { "name": "lodash.takerightwhile", - "version": "4.0.1", + "version": "4.0.2", "description": "The lodash method `_.takeRightWhile` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", "license": "MIT", - "keywords": "lodash, lodash-modularized, stdlib, util, takerightwhile", + "keywords": "lodash-modularized, takerightwhile", "author": "John-David Dalton (http://allyoucanleet.com/)", "contributors": [ "John-David Dalton (http://allyoucanleet.com/)", diff --git a/lodash.takewhile/README.md b/lodash.takewhile/README.md index c572f4e28..f8a29b6e0 100644 --- a/lodash.takewhile/README.md +++ b/lodash.takewhile/README.md @@ -1,4 +1,4 @@ -# lodash.takewhile v4.0.1 +# lodash.takewhile v4.0.2 The [lodash](https://lodash.com/) method `_.takeWhile` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var takeWhile = require('lodash.takewhile'); ``` -See the [documentation](https://lodash.com/docs#takeWhile) or [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash.takewhile) for more details. +See the [documentation](https://lodash.com/docs#takeWhile) or [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash.takewhile) for more details. diff --git a/lodash.takewhile/index.js b/lodash.takewhile/index.js index ee10072e5..5704d965f 100644 --- a/lodash.takewhile/index.js +++ b/lodash.takewhile/index.js @@ -1,5 +1,5 @@ /** - * lodash 4.0.1 (Custom Build) + * lodash 4.0.2 (Custom Build) * Build: `lodash modularize exports="npm" -o ./` * Copyright 2012-2016 The Dojo Foundation * Based on Underscore.js 1.8.3 @@ -31,8 +31,51 @@ var reIsDeepProp = /\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/, /** Used to match backslashes in property paths. */ var reEscapeChar = /\\(\\)?/g; +/** Used to determine if values are of the language type `Object`. */ +var objectTypes = { + 'function': true, + 'object': true +}; + +/** Detect free variable `exports`. */ +var freeExports = (objectTypes[typeof exports] && exports && !exports.nodeType) ? exports : null; + +/** Detect free variable `module`. */ +var freeModule = (objectTypes[typeof module] && module && !module.nodeType) ? module : null; + +/** Detect free variable `global` from Node.js. */ +var freeGlobal = checkGlobal(freeExports && freeModule && typeof global == 'object' && global); + +/** Detect free variable `self`. */ +var freeSelf = checkGlobal(objectTypes[typeof self] && self); + +/** Detect free variable `window`. */ +var freeWindow = checkGlobal(objectTypes[typeof window] && window); + +/** Detect `this` as the global object. */ +var thisGlobal = checkGlobal(objectTypes[typeof this] && this); + +/** + * Used as a reference to the global object. + * + * The `this` value is used if it's the global object to avoid Greasemonkey's + * restricted `window` object, otherwise the `window` object is used. + */ +var root = freeGlobal || ((freeWindow !== (thisGlobal && thisGlobal.window)) && freeWindow) || freeSelf || thisGlobal || Function('return this')(); + +/** + * Checks if `value` is a global object. + * + * @private + * @param {*} value The value to check. + * @returns {null|Object} Returns `value` if it's a global object, else `null`. + */ +function checkGlobal(value) { + return (value && value.Object === Object) ? value : null; +} + /** Used for built-in method references. */ -var objectProto = global.Object.prototype; +var objectProto = Object.prototype; /** * Used to resolve the [`toStringTag`](http://ecma-international.org/ecma-262/6.0/#sec-object.prototype.tostring) @@ -41,7 +84,7 @@ var objectProto = global.Object.prototype; var objectToString = objectProto.toString; /** Built-in value references. */ -var Symbol = global.Symbol; +var Symbol = root.Symbol; /** Used to convert symbols to primitives and strings. */ var symbolProto = Symbol ? Symbol.prototype : undefined, @@ -277,15 +320,15 @@ function stringToPath(string) { * _.takeWhile(users, function(o) { return !o.active; }); * // => objects for ['barney', 'fred'] * - * // using the `_.matches` iteratee shorthand + * // The `_.matches` iteratee shorthand. * _.takeWhile(users, { 'user': 'barney', 'active': false }); * // => objects for ['barney'] * - * // using the `_.matchesProperty` iteratee shorthand + * // The `_.matchesProperty` iteratee shorthand. * _.takeWhile(users, ['active', false]); * // => objects for ['barney', 'fred'] * - * // using the `_.property` iteratee shorthand + * // The `_.property` iteratee shorthand. * _.takeWhile(users, 'active'); * // => [] */ diff --git a/lodash.takewhile/package.json b/lodash.takewhile/package.json index c7925d0bd..2b4c7212a 100644 --- a/lodash.takewhile/package.json +++ b/lodash.takewhile/package.json @@ -1,11 +1,11 @@ { "name": "lodash.takewhile", - "version": "4.0.1", + "version": "4.0.2", "description": "The lodash method `_.takeWhile` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", "license": "MIT", - "keywords": "lodash, lodash-modularized, stdlib, util, takewhile", + "keywords": "lodash-modularized, takewhile", "author": "John-David Dalton (http://allyoucanleet.com/)", "contributors": [ "John-David Dalton (http://allyoucanleet.com/)", diff --git a/lodash.template/README.md b/lodash.template/README.md index 80420c070..bf6fb9629 100644 --- a/lodash.template/README.md +++ b/lodash.template/README.md @@ -1,4 +1,4 @@ -# lodash.template v4.0.1 +# lodash.template v4.0.2 The [lodash](https://lodash.com/) method `_.template` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var template = require('lodash.template'); ``` -See the [documentation](https://lodash.com/docs#template) or [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash.template) for more details. +See the [documentation](https://lodash.com/docs#template) or [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash.template) for more details. diff --git a/lodash.template/index.js b/lodash.template/index.js index 02762054a..fdee5a227 100644 --- a/lodash.template/index.js +++ b/lodash.template/index.js @@ -1,5 +1,5 @@ /** - * lodash 4.0.1 (Custom Build) + * lodash 4.0.2 (Custom Build) * Build: `lodash modularize exports="npm" -o ./` * Copyright 2012-2016 The Dojo Foundation * Based on Underscore.js 1.8.3 @@ -40,6 +40,12 @@ var reNoMatch = /($^)/; /** Used to match unescaped characters in compiled string literals. */ var reUnescapedString = /['\n\r\u2028\u2029\\]/g; +/** Used to determine if values are of the language type `Object`. */ +var objectTypes = { + 'function': true, + 'object': true +}; + /** Used to escape characters for inclusion in compiled string literals. */ var stringEscapes = { '\\': '\\', @@ -50,6 +56,32 @@ var stringEscapes = { '\u2029': 'u2029' }; +/** Detect free variable `exports`. */ +var freeExports = (objectTypes[typeof exports] && exports && !exports.nodeType) ? exports : null; + +/** Detect free variable `module`. */ +var freeModule = (objectTypes[typeof module] && module && !module.nodeType) ? module : null; + +/** Detect free variable `global` from Node.js. */ +var freeGlobal = checkGlobal(freeExports && freeModule && typeof global == 'object' && global); + +/** Detect free variable `self`. */ +var freeSelf = checkGlobal(objectTypes[typeof self] && self); + +/** Detect free variable `window`. */ +var freeWindow = checkGlobal(objectTypes[typeof window] && window); + +/** Detect `this` as the global object. */ +var thisGlobal = checkGlobal(objectTypes[typeof this] && this); + +/** + * Used as a reference to the global object. + * + * The `this` value is used if it's the global object to avoid Greasemonkey's + * restricted `window` object, otherwise the `window` object is used. + */ +var root = freeGlobal || ((freeWindow !== (thisGlobal && thisGlobal.window)) && freeWindow) || freeSelf || thisGlobal || Function('return this')(); + /** * A faster alternative to `Function#apply`, this function invokes `func` * with the `this` binding of `thisArg` and the arguments of `args`. @@ -57,11 +89,11 @@ var stringEscapes = { * @private * @param {Function} func The function to invoke. * @param {*} thisArg The `this` binding of `func`. - * @param {...*} [args] The arguments to invoke `func` with. + * @param {...*} args The arguments to invoke `func` with. * @returns {*} Returns the result of `func`. */ function apply(func, thisArg, args) { - var length = args ? args.length : 0; + var length = args.length; switch (length) { case 0: return func.call(thisArg); case 1: return func.call(thisArg, args[0]); @@ -87,6 +119,17 @@ function baseValues(object, props) { }); } +/** + * Checks if `value` is a global object. + * + * @private + * @param {*} value The value to check. + * @returns {null|Object} Returns `value` if it's a global object, else `null`. + */ +function checkGlobal(value) { + return (value && value.Object === Object) ? value : null; +} + /** * Used by `_.template` to escape characters for inclusion in compiled string literals. * @@ -113,7 +156,7 @@ function isIndex(value, length) { } /** Used for built-in method references. */ -var objectProto = global.Object.prototype; +var objectProto = Object.prototype; /** Used to check objects for own properties. */ var hasOwnProperty = objectProto.hasOwnProperty; @@ -125,7 +168,7 @@ var hasOwnProperty = objectProto.hasOwnProperty; var objectToString = objectProto.toString; /** Built-in value references. */ -var Symbol = global.Symbol; +var Symbol = root.Symbol; /** Used to convert symbols to primitives and strings. */ var symbolProto = Symbol ? Symbol.prototype : undefined, @@ -477,54 +520,54 @@ function toString(value) { * @returns {Function} Returns the compiled template function. * @example * - * // using the "interpolate" delimiter to create a compiled template + * // Use the "interpolate" delimiter to create a compiled template. * var compiled = _.template('hello <%= user %>!'); * compiled({ 'user': 'fred' }); * // => 'hello fred!' * - * // using the HTML "escape" delimiter to escape data property values + * // Use the HTML "escape" delimiter to escape data property values. * var compiled = _.template('<%- value %>'); * compiled({ 'value': '