1
0
mirror of https://gitlab.com/comunic/comunicmobile synced 2024-10-23 06:53:23 +00:00

Fix bad sign out order

This commit is contained in:
Pierre HUBERT 2021-02-13 16:07:23 +01:00
parent e5ed4fadda
commit 0ad8d5c393

View File

@ -79,11 +79,12 @@ class AccountHelper {
/// Sign out user
Future<void> signOut() async {
await APIRequest.withLogin("account/logout").exec();
await (await PreferencesHelper.getInstance()).setLoginToken(null);
_currentUserID = 0;
// Close current web socket
await APIRequest.withLogin("account/logout").exec();
WebSocketHelper.close();
}