TF-3767 Clean up recent searches whenever re-login and exceeds limit

Signed-off-by: dab246 <tdvu@linagora.com>
This commit is contained in:
dab246
2025-06-11 12:59:13 +07:00
committed by Dat H. Pham
parent a02435c9f5
commit 6fef6190e0
13 changed files with 136 additions and 61 deletions
@@ -42,7 +42,10 @@ extension ListRecentSearchCacheExtension on List<RecentSearchCache> {
void sortByCreationDate() {
sort((recentSearch1, recentSearch2) {
return recentSearch1.creationDate.compareToSort(recentSearch1.creationDate, false);
return recentSearch1.creationDate.compareToSort(
recentSearch2.creationDate,
false,
);
});
}
}