There was previously a problem where you would somehow become another user. This commit (182ba06) was aimed at fixing, but I would like @phlipper to double check to understand what was going on and determine what the original issue was and verify that this is resolved.
This was happening upon login. In the case @bousquet, @elskwid and I were looking at the user (who could be redirected to one of two places, depending on the type of user) was being redirected to the place that made sense for the prior user we had logged in with.
This commit looks good to me. I am going to close out this issue and we can re-open a new issue with reproducible steps if this regression resurfaces.