Oops. Fix for logout() function. Copy-paste is an evil