From d5ba17909f7b93a60f998960eba4abbbb7315ac9 Mon Sep 17 00:00:00 2001 From: Julian KOUNE Date: Thu, 7 Sep 2023 10:06:55 +0200 Subject: [PATCH] fixup! fixup! fix: clean tom db on logout --- lib/data/hive/hive_collection_tom_database.dart | 2 +- lib/widgets/matrix.dart | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/lib/data/hive/hive_collection_tom_database.dart b/lib/data/hive/hive_collection_tom_database.dart index 3fc41f2667..c66504e431 100644 --- a/lib/data/hive/hive_collection_tom_database.dart +++ b/lib/data/hive/hive_collection_tom_database.dart @@ -123,7 +123,7 @@ class HiveCollectionToMDatabase { Logs().w('Delete database and storage key...'); await const FlutterSecureStorage() .delete(key: FlutterHiveCollectionsDatabase.cipherStorageKey); - await _collection.deleteFromDisk(); + await tomConfigurationsBox.clear(); await Hive.deleteFromDisk(); } } diff --git a/lib/widgets/matrix.dart b/lib/widgets/matrix.dart index cce66c54d6..db700fbe33 100644 --- a/lib/widgets/matrix.dart +++ b/lib/widgets/matrix.dart @@ -360,6 +360,7 @@ class MatrixState extends State with WidgetsBindingObserver { navigatorContext?.go('/rooms'); } else { await getIt.get().clear(); + await c.clear(); } } });