ol-infrastructure
ol-infrastructure copied to clipboard
Use bereq object for managing implicit redirects in MIT Learn
In the MIT Learn application, if someone hits the http -> https redirect the first time it leaks the path rewriting that is done for managing the React routing state. This results in a 404 and bad UX
Expected Behavior
The user cleanly redirects from http -> https without getting a 404
Current Behavior
The user gets a 404 because of trying to load /frontend/index.html
Steps to Reproduce
- In a clean session go to
http://learn.mit.edu
Possible Solution
Move the path rewriting to a fetch
stage snippet and manipulate the bereq.url
instead of req.url