fix logout button and double triggered connection. #15