code: function matches(str, match) {
      if (Array.isArray(match)) return match.indexOf(str) > -1;
      return match.test(str);
  }
docs: determine if a string is contained within an array or matches a regular expression
  @param   {String} str string to match
  @param   {Array|Regex} match array or regular expression to match against
  @returns {Boolean} whether there is a match