diff --git a/README.md b/README.md
index 63cedb139..a0bedb9eb 100644
--- a/README.md
+++ b/README.md
@@ -1,4 +1,4 @@
-# lodash v3.5.0
+# lodash v3.5.1
The [lodash](https://lodash.com/) library exported as [npm packages](https://www.npmjs.com/browse/keyword/lodash-modularized) per method.
diff --git a/lodash._basesortbyorder/README.md b/lodash._basesortbyorder/README.md
index ecde71705..10f350b24 100644
--- a/lodash._basesortbyorder/README.md
+++ b/lodash._basesortbyorder/README.md
@@ -1,4 +1,4 @@
-# lodash._basesortbyorder v3.5.0
+# lodash._basesortbyorder v3.5.1
The [modern build](https://github.com/lodash/lodash/wiki/Build-Differences) of [lodash’s](https://lodash.com/) internal `baseSortByOrder` exported as a [Node.js](http://nodejs.org/)/[io.js](https://iojs.org/) module.
@@ -17,4 +17,4 @@ In Node.js/io.js:
var baseSortByOrder = require('lodash._basesortbyorder');
```
-See the [package source](https://github.com/lodash/lodash/blob/3.5.0-npm-packages/lodash._basesortbyorder) for more details.
+See the [package source](https://github.com/lodash/lodash/blob/3.5.1-npm-packages/lodash._basesortbyorder) for more details.
diff --git a/lodash._basesortbyorder/index.js b/lodash._basesortbyorder/index.js
index 10b049979..b255cf454 100644
--- a/lodash._basesortbyorder/index.js
+++ b/lodash._basesortbyorder/index.js
@@ -1,5 +1,5 @@
/**
- * lodash 3.5.0 (Custom Build)
+ * lodash 3.5.1 (Custom Build)
* Build: `lodash modern modularize exports="npm" -o ./`
* Copyright 2012-2015 The Dojo Foundation
* Based on Underscore.js 1.8.3
@@ -69,8 +69,7 @@ var MAX_SAFE_INTEGER = Math.pow(2, 53) - 1;
*/
function baseMap(collection, iteratee) {
var index = -1,
- length = getLength(collection),
- result = isLength(length) ? Array(length) : [];
+ result = isArrayLike(collection) ? Array(collection.length) : [];
baseEach(collection, function(value, key, collection) {
result[++index] = iteratee(value, key, collection);
@@ -119,7 +118,7 @@ function baseSortByOrder(collection, iteratees, orders) {
* 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)
- * in Safari on iOS 8.1 ARM64.
+ * that affects Safari on at least iOS 8.1-8.3 ARM64.
*
* @private
* @param {Object} object The object to query.
@@ -127,6 +126,17 @@ function baseSortByOrder(collection, iteratees, orders) {
*/
var getLength = baseProperty('length');
+/**
+ * Checks if `value` is array-like.
+ *
+ * @private
+ * @param {*} value The value to check.
+ * @returns {boolean} Returns `true` if `value` is array-like, else `false`.
+ */
+function isArrayLike(value) {
+ return value != null && isLength(getLength(value));
+}
+
/**
* Checks if `value` is a valid array-like length.
*
diff --git a/lodash._basesortbyorder/package.json b/lodash._basesortbyorder/package.json
index 0224ef3d2..9f6df5ac1 100644
--- a/lodash._basesortbyorder/package.json
+++ b/lodash._basesortbyorder/package.json
@@ -1,6 +1,6 @@
{
"name": "lodash._basesortbyorder",
- "version": "3.5.0",
+ "version": "3.5.1",
"description": "The modern build of lodash’s internal `baseSortByOrder` as a module.",
"homepage": "https://lodash.com/",
"icon": "https://lodash.com/icon.svg",
diff --git a/lodash.template/README.md b/lodash.template/README.md
index 6c927c16a..b6a0ba07a 100644
--- a/lodash.template/README.md
+++ b/lodash.template/README.md
@@ -1,4 +1,4 @@
-# lodash.template v3.5.0
+# lodash.template v3.5.1
The [modern build](https://github.com/lodash/lodash/wiki/Build-Differences) of [lodash’s](https://lodash.com/) `_.template` exported as a [Node.js](http://nodejs.org/)/[io.js](https://iojs.org/) module.
@@ -17,4 +17,4 @@ In Node.js/io.js:
var template = require('lodash.template');
```
-See the [documentation](https://lodash.com/docs#template) or [package source](https://github.com/lodash/lodash/blob/3.5.0-npm-packages/lodash.template) for more details.
+See the [documentation](https://lodash.com/docs#template) or [package source](https://github.com/lodash/lodash/blob/3.5.1-npm-packages/lodash.template) for more details.
diff --git a/lodash.template/index.js b/lodash.template/index.js
index a2b644f84..3a2a40836 100644
--- a/lodash.template/index.js
+++ b/lodash.template/index.js
@@ -1,5 +1,5 @@
/**
- * lodash 3.5.0 (Custom Build)
+ * lodash 3.5.1 (Custom Build)
* Build: `lodash modern modularize exports="npm" -o ./`
* Copyright 2012-2015 The Dojo Foundation
* Based on Underscore.js 1.8.3
@@ -82,24 +82,7 @@ var objToString = objectProto.toString;
/** Native method references. */
var getOwnPropertySymbols = isNative(getOwnPropertySymbols = Object.getOwnPropertySymbols) && getOwnPropertySymbols,
- push = arrayProto.push,
- preventExtensions = isNative(Object.preventExtensions = Object.preventExtensions) && preventExtensions;
-
-/** Used as `baseAssign`. */
-var nativeAssign = (function() {
- // Avoid `Object.assign` in Firefox 34-37 which have an early implementation
- // with a now defunct try/catch behavior. See https://bugzilla.mozilla.org/show_bug.cgi?id=1103344
- // for more details.
- //
- // Use `Object.preventExtensions` on a plain object instead of simply using
- // `Object('x')` because Chrome and IE fail to throw an error when attempting
- // to assign values to readonly indexes of strings in strict mode.
- var object = { '1': 0 },
- func = preventExtensions && isNative(func = Object.assign) && func;
-
- try { func(preventExtensions(object), 'xo'); } catch(e) {}
- return !object[1] && func;
-}());
+ push = arrayProto.push;
/**
* Used by `_.template` to customize its `_.assign` use.
@@ -160,7 +143,7 @@ function assignWith(object, source, customizer) {
* @param {Object} source The source object.
* @returns {Object} Returns `object`.
*/
-var baseAssign = nativeAssign || function(object, source) {
+var baseAssign = function(object, source) {
return source == null
? object
: baseCopy(source, getSymbols(source), baseCopy(source, keys(source), object));
diff --git a/lodash.template/package.json b/lodash.template/package.json
index 86636d607..ce3608a2f 100644
--- a/lodash.template/package.json
+++ b/lodash.template/package.json
@@ -1,6 +1,6 @@
{
"name": "lodash.template",
- "version": "3.5.0",
+ "version": "3.5.1",
"description": "The modern build of lodash’s `_.template` as a module.",
"homepage": "https://lodash.com/",
"icon": "https://lodash.com/icon.svg",