diff --git a/README.md b/README.md index 025bbb6b7..b7282199f 100644 --- a/README.md +++ b/README.md @@ -1,4 +1,4 @@ -# lodash v3.1.5 +# lodash v3.1.6 The [lodash](https://lodash.com/) library exported as [npm packages](https://www.npmjs.com/browse/keyword/lodash-modularized) per method. diff --git a/lodash.random/README.md b/lodash.random/README.md index e16dc387e..423d3cb57 100644 --- a/lodash.random/README.md +++ b/lodash.random/README.md @@ -1,4 +1,4 @@ -# lodash.random v3.1.5 +# lodash.random v3.1.6 The [lodash](https://lodash.com/) method `_.random` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var random = require('lodash.random'); ``` -See the [documentation](https://lodash.com/docs#random) or [package source](https://github.com/lodash/lodash/blob/3.1.5-npm-packages/lodash.random) for more details. +See the [documentation](https://lodash.com/docs#random) or [package source](https://github.com/lodash/lodash/blob/3.1.6-npm-packages/lodash.random) for more details. diff --git a/lodash.random/index.js b/lodash.random/index.js index 4d41651d0..de2e8e0e9 100644 --- a/lodash.random/index.js +++ b/lodash.random/index.js @@ -35,6 +35,19 @@ var reIsUint = /^(?:0|[1-9]\d*)$/; var freeParseFloat = parseFloat, freeParseInt = parseInt; +/** + * 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 accessor function. + */ +function baseProperty(key) { + return function(object) { + return object == null ? undefined : object[key]; + }; +} + /** Used for built-in method references. */ var objectProto = Object.prototype; @@ -50,19 +63,6 @@ var nativeFloor = Math.floor, nativeMin = Math.min, nativeRandom = Math.random; -/** - * 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 accessor function. - */ -function baseProperty(key) { - return function(object) { - return object == null ? undefined : object[key]; - }; -} - /** * The base implementation of `_.random` without support for returning * floating-point numbers. @@ -142,8 +142,8 @@ function isIterateeCall(value, index, object) { * @returns {boolean} Returns `true` if the values are equivalent, else `false`. * @example * - * var object = { 'user': 'fred' }; - * var other = { 'user': 'fred' }; + * var object = { 'a': 1 }; + * var other = { 'a': 1 }; * * _.eq(object, object); * // => true @@ -201,8 +201,7 @@ function isArrayLike(value) { * @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(_); @@ -317,8 +316,7 @@ function isObjectLike(value) { * @since 4.0.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 symbol, else `false`. * @example * * _.isSymbol(Symbol.iterator); diff --git a/lodash.random/package.json b/lodash.random/package.json index 90ed22e68..431940df2 100644 --- a/lodash.random/package.json +++ b/lodash.random/package.json @@ -1,6 +1,6 @@ { "name": "lodash.random", - "version": "3.1.5", + "version": "3.1.6", "description": "The lodash method `_.random` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg", diff --git a/lodash.range/README.md b/lodash.range/README.md index cef25bcf0..7a2d6c4cd 100644 --- a/lodash.range/README.md +++ b/lodash.range/README.md @@ -1,4 +1,4 @@ -# lodash.range v3.1.5 +# lodash.range v3.1.6 The [lodash](https://lodash.com/) method `_.range` exported as a [Node.js](https://nodejs.org/) module. @@ -15,4 +15,4 @@ In Node.js: var range = require('lodash.range'); ``` -See the [documentation](https://lodash.com/docs#range) or [package source](https://github.com/lodash/lodash/blob/3.1.5-npm-packages/lodash.range) for more details. +See the [documentation](https://lodash.com/docs#range) or [package source](https://github.com/lodash/lodash/blob/3.1.6-npm-packages/lodash.range) for more details. diff --git a/lodash.range/index.js b/lodash.range/index.js index ec5f125b8..1815f92f1 100644 --- a/lodash.range/index.js +++ b/lodash.range/index.js @@ -34,6 +34,19 @@ var reIsUint = /^(?:0|[1-9]\d*)$/; /** Built-in method references without a dependency on `root`. */ var freeParseInt = parseInt; +/** + * 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 accessor function. + */ +function baseProperty(key) { + return function(object) { + return object == null ? undefined : object[key]; + }; +} + /** Used for built-in method references. */ var objectProto = Object.prototype; @@ -48,22 +61,9 @@ var objectToString = objectProto.toString; var nativeCeil = Math.ceil, nativeMax = Math.max; -/** - * 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 accessor function. - */ -function baseProperty(key) { - return function(object) { - return object == null ? undefined : object[key]; - }; -} - /** * The base implementation of `_.range` and `_.rangeRight` which doesn't - * coerce arguments to numbers. + * coerce arguments. * * @private * @param {number} start The start of the range. @@ -176,8 +176,8 @@ function isIterateeCall(value, index, object) { * @returns {boolean} Returns `true` if the values are equivalent, else `false`. * @example * - * var object = { 'user': 'fred' }; - * var other = { 'user': 'fred' }; + * var object = { 'a': 1 }; + * var other = { 'a': 1 }; * * _.eq(object, object); * // => true @@ -235,8 +235,7 @@ function isArrayLike(value) { * @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(_); @@ -351,8 +350,7 @@ function isObjectLike(value) { * @since 4.0.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 symbol, else `false`. * @example * * _.isSymbol(Symbol.iterator); diff --git a/lodash.range/package.json b/lodash.range/package.json index ae8262f82..94d0753f8 100644 --- a/lodash.range/package.json +++ b/lodash.range/package.json @@ -1,6 +1,6 @@ { "name": "lodash.range", - "version": "3.1.5", + "version": "3.1.6", "description": "The lodash method `_.range` exported as a module.", "homepage": "https://lodash.com/", "icon": "https://lodash.com/icon.svg",