TF-474 Fix data in cache not show correctly after logout

This commit is contained in:
dab246
2022-04-12 11:41:14 +07:00
committed by Dat H. Pham
parent 04ef997eb4
commit b4fd1ce5e5
7 changed files with 50 additions and 10 deletions
@@ -118,4 +118,14 @@ class StateCacheClient extends HiveCacheClient<StateCache> {
throw error;
});
}
@override
Future<void> clearAllData() {
return Future.sync(() async {
final boxState = await openBox();
boxState.clear();
}).catchError((error) {
throw error;
});
}
}