rsnext/packages/next/next-server
Anthony Short 61c4cdb501
Avoid adding basePath when it's not needed (#14535)
* Avoid adding basePath when it's not needed

When using the `basePath` setting, on pages with params it will fire a router change. This will pass the url pathname in the `as` param using the `getUrl()` function. This means the `as` path will be sent through already including the `basePath`, leading to `/basePath/basePath/path` which will cause the router to throw an error.

* lint

* Add test case and ensure removal

* Make sure to re-add before changeState

Co-authored-by: JJ Kasper <jj@jjsweb.site>
2020-06-24 21:36:22 -05:00
..
lib Avoid adding basePath when it's not needed (#14535) 2020-06-24 21:36:22 -05:00
server Normalize trailing slashes (#13333) 2020-06-23 13:38:49 +02:00