Fixed bug with redirect through session management