1 var arrayCopy = require('../internal/arrayCopy'),
2 getLength = require('../internal/getLength'),
3 isLength = require('../internal/isLength'),
4 values = require('../object/values');
7 * Converts `value` to an array.
12 * @param {*} value The value to convert.
13 * @returns {Array} Returns the converted array.
17 * return _.toArray(arguments).slice(1);
21 function toArray(value) {
22 var length = value ? getLength(value) : 0;
23 if (!isLength(length)) {
29 return arrayCopy(value);
32 module.exports = toArray;