page.js icon indicating copy to clipboard operation
page.js copied to clipboard

fix: don't fail on routes that begin with the page base setting

Open andyburke opened this issue 5 years ago • 6 comments

This resolves an issue where if you set the base to something that matches the beginning of one of your routes, things will not work properly. Eg:

page.base( '/en' ); // set to english localization

If you have a route like '/enroll', this will cause errors.

This change fixes the issue.

andyburke avatar Nov 14 '19 23:11 andyburke

Coverage Status

Coverage remained the same at 92.531% when pulling 35e8c5f8ccea7700980c3057c45f668d3e76284a on andyburke-forks:base_fix into 0d7e127037abd021fa299e2d8d0a4b727476712f on visionmedia:master.

coveralls avatar Nov 14 '19 23:11 coveralls

Coverage Status

Coverage remained the same at 92.531% when pulling 05a745da9a9201d45c8613eb6b0742959b51359b on andyburke-forks:base_fix into 0d7e127037abd021fa299e2d8d0a4b727476712f on visionmedia:master.

coveralls avatar Nov 14 '19 23:11 coveralls

Thanks for adding a test!

It looks like compiling made a whole bunch of changes that were related to your change. Why is that?

matthewp avatar Nov 24 '19 21:11 matthewp

I honestly don't know. I just tried re-running npm install to see if I somehow have a different version of whatever libraries are used to compile, but I don't think I do.

Is there a way you could pull the branch and try to build and see if the same thing is happening?

andyburke avatar Dec 03 '19 02:12 andyburke

Yeah I can do that, probably not until this weekend though.

matthewp avatar Dec 04 '19 13:12 matthewp

Any update on this?

andyburke avatar Dec 17 '19 01:12 andyburke