illinois / queue

A microservice queue for holding open office hours
University of Illinois/NCSA Open Source License
82 stars 36 forks source link

Implement redirecting to landing url after login #208

Closed james9909 closed 5 years ago

james9909 commented 5 years ago

Adds a redirect query parameter to the login route if an unauthenticated user lands on an authenticated route. Also fixes an issue I was having with safeAsync when writing tests for this new functionality.

Closes #188.

vercel[bot] commented 5 years ago

This pull request is automatically deployed with Now. To access deployments, click Details below or on the icon next to each push.

trombonekenny commented 5 years ago

I solved this problem of returning to the pre-auth URL after auth in PrairieLearn with another cookie. It was much cleaner than query parameter parsing and was surprisingly easy to add (only 3-4 lines of code in the right place in the auth code).