Fix name function to do_login and do_logout