TF-3487 Handle get email content failure
This commit is contained in:
@@ -51,5 +51,6 @@ class GetEmailContentFromCacheSuccess extends UIState {
|
||||
|
||||
class GetEmailContentFailure extends FeatureFailure {
|
||||
|
||||
GetEmailContentFailure(dynamic exception) : super(exception: exception);
|
||||
GetEmailContentFailure(dynamic exception, {super.onRetry})
|
||||
: super(exception: exception);
|
||||
}
|
||||
@@ -49,7 +49,17 @@ class GetEmailContentInteractor {
|
||||
}
|
||||
} catch (e) {
|
||||
log('GetEmailContentInteractor::execute(): exception = $e');
|
||||
yield Left<Failure, Success>(GetEmailContentFailure(e));
|
||||
yield Left<Failure, Success>(GetEmailContentFailure(
|
||||
e,
|
||||
onRetry: execute(
|
||||
session,
|
||||
accountId,
|
||||
emailId,
|
||||
baseDownloadUrl,
|
||||
transformConfiguration,
|
||||
additionalProperties: additionalProperties
|
||||
),
|
||||
));
|
||||
}
|
||||
}
|
||||
|
||||
@@ -97,7 +107,17 @@ class GetEmailContentInteractor {
|
||||
}
|
||||
} catch (e) {
|
||||
logError('GetEmailContentInteractor::_getContentEmailFromServer():EXCEPTION: $e');
|
||||
yield Left<Failure, Success>(GetEmailContentFailure(e));
|
||||
yield Left<Failure, Success>(GetEmailContentFailure(
|
||||
e,
|
||||
onRetry: execute(
|
||||
session,
|
||||
accountId,
|
||||
emailId,
|
||||
baseDownloadUrl,
|
||||
transformConfiguration,
|
||||
additionalProperties: additionalProperties
|
||||
),
|
||||
));
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user