* fixed some issues on logout