moved login function to menu activity