Code cleanup of user login and session management and redirects, following the solutions video