Closed sayoder closed 7 years ago
Hmm, I tried doing this before and it seemed to cause trouble. Both myself and @mray experienced getting redirected away from Snowdrift when I tried using redirectUltDest. Like a lot of Yesod, I think this needs a first-principles review and possibly refactor.
I could swear I remember that Snowdrift handled this manually, but I'm looking through the code now and not finding it. :/ @wolftune do you remember if/when that would have been true? I can look more....
I mean Snowdrift historically* handled it. Some time in the past.
At one time in the past, it worked and had no issues too. We have no clue why the bug started happening.
I applied the patch to the branch I was working on for the Discourse SSO, and this corrected the issue we were having. Not knowing what happened in the past and also considering all the extra stuff that was stripped out previously, there's no guarantee that we won't experience any issues down the road as we start to add stuff back in. That being said, if we create some tests for this, should there be any issues down the road, we may get a better idea of what's causing issues at this point and fix it properly so that the redirect continues to work.
On Tue, Dec 6, 2016 at 10:24 PM, Aaron Wolf notifications@github.com wrote:
At one time in the past, it worked and had no issues too. We have no clue why the bug started happening.
— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/snowdriftcoop/snowdrift/pull/333#issuecomment-265352295, or mute the thread https://github.com/notifications/unsubscribe-auth/ABLOQl9gJ9WUEUW5v7nYHL8OtfoaVFqmks5rFjT8gaJpZM4LF0cJ .
I'm merging. Let's worry about any issues when/if they arise
Yesod handily passes along an "ultimate destination", which we can use to redirect the user back to the page that they originally requested. To see this in action, visit
/payment-info
while logged out. After logging in, the user is now redirected to/payment-info
instead of/dashboard
.