mirror of
https://github.com/whoisclebs/lodash.git
synced 2026-02-07 18:07:49 +00:00
Use the new operator with the Array constructor.
This commit is contained in:
@@ -7,7 +7,7 @@
|
||||
*/
|
||||
function setToPairs(set) {
|
||||
let index = -1
|
||||
const result = Array(set.size)
|
||||
const result = new Array(set.size)
|
||||
|
||||
set.forEach((value) =>
|
||||
result[++index] = [value, value]
|
||||
|
||||
Reference in New Issue
Block a user