function matcher(path) {
  const params = [];
  const rx = pathRegexp(path, params);

  return function(pathname) {