Fixing issue where user not redirected to page they wanted to access after logging in.