TF-1487 Apply linter rule
This commit is contained in:
@@ -25,9 +25,7 @@ class SearchDataSourceImpl extends SearchDataSource {
|
||||
recentSearch.value,
|
||||
recentSearch.toRecentSearchCache());
|
||||
}
|
||||
}).catchError((error) {
|
||||
_exceptionThrower.throwException(error);
|
||||
});
|
||||
}).catchError(_exceptionThrower.throwException);
|
||||
}
|
||||
|
||||
@override
|
||||
@@ -47,9 +45,7 @@ class SearchDataSourceImpl extends SearchDataSource {
|
||||
: listRecentSearch;
|
||||
|
||||
return newListRecentSearch;
|
||||
}).catchError((error) {
|
||||
_exceptionThrower.throwException(error);
|
||||
});
|
||||
}).catchError(_exceptionThrower.throwException);
|
||||
}
|
||||
|
||||
bool _filterRecentSearchCache(RecentSearchCache recentSearchCache, String? pattern) {
|
||||
|
||||
+6
-18
@@ -16,27 +16,21 @@ class SharePreferenceSpamReportDataSourceImpl extends SpamReportDataSource {
|
||||
Future<DateTime> getLastTimeDismissedSpamReported() async {
|
||||
return Future.sync(() async {
|
||||
return await _sharePreferenceSpamReportDataSource.getLastTimeDismissedSpamReported();
|
||||
}).catchError((error) {
|
||||
_exceptionThrower.throwException(error);
|
||||
});
|
||||
}).catchError(_exceptionThrower.throwException);
|
||||
}
|
||||
|
||||
@override
|
||||
Future<bool> storeLastTimeDismissedSpamReported(DateTime lastTimeDismissedSpamReported) async {
|
||||
return Future.sync(() async {
|
||||
return await _sharePreferenceSpamReportDataSource.storeLastTimeDismissedSpamReported(lastTimeDismissedSpamReported);
|
||||
}).catchError((error) {
|
||||
_exceptionThrower.throwException(error);
|
||||
});
|
||||
}).catchError(_exceptionThrower.throwException);
|
||||
}
|
||||
|
||||
@override
|
||||
Future<bool> deleteLastTimeDismissedSpamReported() {
|
||||
return Future.sync(() async {
|
||||
return await _sharePreferenceSpamReportDataSource.deleteLastTimeDismissedSpamReported();
|
||||
}).catchError((error) {
|
||||
_exceptionThrower.throwException(error);
|
||||
});
|
||||
}).catchError(_exceptionThrower.throwException);
|
||||
}
|
||||
|
||||
@override
|
||||
@@ -54,26 +48,20 @@ class SharePreferenceSpamReportDataSourceImpl extends SpamReportDataSource {
|
||||
Future<void> deleteSpamReportState() {
|
||||
return Future.sync(() async {
|
||||
return await _sharePreferenceSpamReportDataSource.deleteLastTimeDismissedSpamReported();
|
||||
}).catchError((error) {
|
||||
_exceptionThrower.throwException(error);
|
||||
});
|
||||
}).catchError(_exceptionThrower.throwException);
|
||||
}
|
||||
|
||||
@override
|
||||
Future<SpamReportState> getSpamReportState() {
|
||||
return Future.sync(() async {
|
||||
return await _sharePreferenceSpamReportDataSource.getSpamReportState();
|
||||
}).catchError((error) {
|
||||
_exceptionThrower.throwException(error);
|
||||
});
|
||||
}).catchError(_exceptionThrower.throwException);
|
||||
}
|
||||
|
||||
@override
|
||||
Future<void> storeSpamReportState(SpamReportState spamReportState) {
|
||||
return Future.sync(() async {
|
||||
return await _sharePreferenceSpamReportDataSource.storeSpamReportState(spamReportState);
|
||||
}).catchError((error) {
|
||||
_exceptionThrower.throwException(error);
|
||||
});
|
||||
}).catchError(_exceptionThrower.throwException);
|
||||
}
|
||||
}
|
||||
|
||||
+3
-5
@@ -28,12 +28,10 @@ class SpamReportDataSourceImpl extends SpamReportDataSource {
|
||||
}
|
||||
) {
|
||||
return Future.sync(() async {
|
||||
final _unreadSpamEmailsResponse = await _spamReportApi.getUnreadSpamEmailbox(
|
||||
final unreadSpamEmailsResponse = await _spamReportApi.getUnreadSpamEmailbox(
|
||||
accountId, mailboxFilterCondition: mailboxFilterCondition, limit: limit);
|
||||
return _unreadSpamEmailsResponse;
|
||||
}).catchError((error) {
|
||||
_exceptionThrower.throwException(error);
|
||||
});
|
||||
return unreadSpamEmailsResponse;
|
||||
}).catchError(_exceptionThrower.throwException);
|
||||
}
|
||||
|
||||
@override
|
||||
|
||||
Reference in New Issue
Block a user