index.js
function normalizeList (val, name) {
  var list = [].concat(val || [])

  for (var i = 0; i < list.length; i++) {
    if (typeof list[i] !== 'string') {
      throw new TypeError(name + ' must be array of strings or false')
    }
  }

  return list
}
function normalizeList (val, name) {
  var list = [].concat(val || [])

  for (var i = 0; i < list.length; i++) {
    if (typeof list[i] !== 'string') {
      throw new TypeError(name + ' must be array of strings or false')
    }
  }

  return list
}
function normalizeList ( val , name ) { var list = [ ] . concat ( val || [ ] ) for ( var i = 0 ; i < list . length ; i ++ ) { if ( typeof list [ i ] !== 'string' ) { throw new TypeError ( name + ' must be array of strings or false' ) } } return list }
Normalize the index option into an array.

@param {boolean|string|array} val
@param {string} name
@private
Normalize the index option into an array .