Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

BB-481: Fix merged entities path redirect #429

Merged
merged 2 commits into from
May 26, 2020
Merged

Conversation

MonkeyDo
Copy link
Contributor

Problem

Links to merged bbids subpaths (for example /$BBID/revisions) would redirect to the merged entity without the subpath (i.e: /$newBBID).

Solution

Replace the bbid in the full path and redirect to that.

This PR also puts entity routes without BBIDs (/create, /create/handler) before the route parameters are defined for routes with bbids.
This allows us to remove an ugly solution to detect routes without bbid introduced in this commit:
0e1a834#diff-04b1046083d3d54b6df49ebe87477558

Also adds a bit of flow types

Areas of Impact

Entity router files and middleware helpers.

Also remove special case for '/create' routes (see previous commit), and  added types
@coveralls
Copy link

Coverage Status

Coverage increased (+0.007%) to 60.251% when pulling 7dc9642 on fix-routes-redirect into f340035 on master.

@MonkeyDo MonkeyDo merged commit 77fccbb into master May 26, 2020
@MonkeyDo MonkeyDo deleted the fix-routes-redirect branch May 26, 2020 11:50
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
2 participants