fix a relogin bug