Fix bug: Cannot logout after login on Android and iOS