refactoring the menu based on login/logout