rsnext/errors/invalid-multi-match.md
JJ Kasper ff2d28c4ff Add err.sh for invalid multi-match usage (#9498)
* Adds err.sh for multi-match error

* Fix missing apostrophe

* Update regex to catch other param names

* Add test for multi-match error

* Update test/integration/invalid-multi-match/test/index.test.js
2019-11-23 02:23:01 +01:00

497 B

Invalid Multi-match

Why This Error Occurred

In one of your custom-routes you specified a multi-match /:path* and used it in your destination without adding the * in your destination e.g. destination: '/another/:path'

Possible Ways to Fix It

Add * to your usage of the multi-match param in your destination.

Before

{
  source: '/:path*',
  destination: '/another/:path'
}

After

{
  source: '/:path*',
  destination: '/another/:path*'
}