1 var baseUnset = require('./_baseUnset'),
2 isIndex = require('./_isIndex');
4 /** Used for built-in method references. */
5 var arrayProto = Array.prototype;
7 /** Built-in value references. */
8 var splice = arrayProto.splice;
11 * The base implementation of `_.pullAt` without support for individual
12 * indexes or capturing the removed elements.
15 * @param {Array} array The array to modify.
16 * @param {number[]} indexes The indexes of elements to remove.
17 * @returns {Array} Returns `array`.
19 function basePullAt(array, indexes) {
20 var length = array ? indexes.length : 0,
21 lastIndex = length - 1;
24 var index = indexes[length];
25 if (length == lastIndex || index !== previous) {
28 splice.call(array, index, 1);
30 baseUnset(array, index);
37 module.exports = basePullAt;