TF-1933 Add GetStoredSendingEmail interactor
(cherry picked from commit bcf27cbaa5fbc62767a82e658e543339c5197991)
This commit is contained in:
@@ -219,4 +219,9 @@ class EmailDataSourceImpl extends EmailDataSource {
|
||||
Future<List<SendingEmail>> deleteMultipleSendingEmail(AccountId accountId, UserName userName, List<String> sendingIds) {
|
||||
throw UnimplementedError();
|
||||
}
|
||||
|
||||
@override
|
||||
Future<SendingEmail> getStoredSendingEmail(AccountId accountId, UserName userName, String sendingId) {
|
||||
throw UnimplementedError();
|
||||
}
|
||||
}
|
||||
@@ -279,4 +279,12 @@ class EmailHiveCacheDataSourceImpl extends EmailDataSource {
|
||||
return await _sendingEmailCacheManager.deleteMultipleSendingEmail(accountId, userName, sendingIds);
|
||||
}).catchError(_exceptionThrower.throwException);
|
||||
}
|
||||
|
||||
@override
|
||||
Future<SendingEmail> getStoredSendingEmail(AccountId accountId, UserName userName, String sendingId) {
|
||||
return Future.sync(() async {
|
||||
final sendingEmailCache = await _sendingEmailCacheManager.getStoredSendingEmail(accountId, userName, sendingId);
|
||||
return sendingEmailCache.toSendingEmail();
|
||||
}).catchError(_exceptionThrower.throwException);
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user