mirror of
https://github.com/whoisclebs/lodash.git
synced 2026-02-03 00:27:50 +00:00
Apply more let/const transforms.
This commit is contained in:
@@ -1,8 +1,8 @@
|
||||
/** Used for built-in method references. */
|
||||
var objectProto = Object.prototype;
|
||||
const objectProto = Object.prototype;
|
||||
|
||||
/** Used to check objects for own properties. */
|
||||
var hasOwnProperty = objectProto.hasOwnProperty;
|
||||
const hasOwnProperty = objectProto.hasOwnProperty;
|
||||
|
||||
/**
|
||||
* Initializes an array clone.
|
||||
@@ -12,8 +12,8 @@ var hasOwnProperty = objectProto.hasOwnProperty;
|
||||
* @returns {Array} Returns the initialized clone.
|
||||
*/
|
||||
function initCloneArray(array) {
|
||||
var length = array.length,
|
||||
result = array.constructor(length);
|
||||
const length = array.length;
|
||||
const result = array.constructor(length);
|
||||
|
||||
// Add properties assigned by `RegExp#exec`.
|
||||
if (length && typeof array[0] == 'string' && hasOwnProperty.call(array, 'index')) {
|
||||
|
||||
Reference in New Issue
Block a user