Fixed #51, No longer redirecting to the wrong page after login.