fix bug when user is logged in but does not exist anymoer