Added logic to user login redirection