skipRegexesWrapper = function(regexes, fn) {

    // Remove anything that's not a regex
    regexes = _.compact(regexes.map(function(regex) {
      if (regex instanceof RegExp) {
        return regex;
      }
      sails.log.warn('Invalid regex "' + regex + '" supplied to skipRegexesWrapper; ignoring.');
      return undefined;
    }));


    return function(req, res, next) {

      // Check for matches
      for (var i = 0; i < regexes.length; i++) {
        if (req.url.match(regexes[i])) {
          // If we find one, bail out
          return next();
        }
      }

      // - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
      // TODO: Need to double-check on this, but shouldn't this call `enhancedFn`, instead of just `fn`?
      // If so, then we can just make that change.  Otherwise, we need to do more here.
      // - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -

      // Otherwise continue with the handler
      return fn(req, res, next);

    };

  }
Wrap a route in a helper function that first checks whether the URL matches
any of a set of regexes, and if so, skips the defined handler.

@param  {array}   regexes Array of regexes to match the URL against
@param  {Function} fn      Middleware function to run if URL does NOT match regexes
@return {Function} A middleware function