TF-629 Download file and get the contentType to open file in Android/iOS
This commit is contained in:
committed by
Dat H. Pham
parent
40a470dc21
commit
ee692d52a2
@@ -35,7 +35,7 @@ class ExportAttachmentInteractor {
|
||||
|
||||
log('ExportAttachmentInteractor::execute(): account: $account');
|
||||
|
||||
final filePath = await Future.wait([
|
||||
final downloadedResponse = await Future.wait([
|
||||
if (account.authenticationType == AuthenticationType.oidc)
|
||||
_authenticationOIDCRepository.getStoredTokenOIDC(account.id)
|
||||
else
|
||||
@@ -66,7 +66,7 @@ class ExportAttachmentInteractor {
|
||||
accountRequest,
|
||||
cancelToken);
|
||||
});
|
||||
yield Right<Failure, Success>(ExportAttachmentSuccess(filePath));
|
||||
yield Right<Failure, Success>(ExportAttachmentSuccess(downloadedResponse));
|
||||
} catch (exception) {
|
||||
log('ExportAttachmentInteractor::execute(): exception: $exception');
|
||||
yield Left<Failure, Success>(ExportAttachmentFailure(exception));
|
||||
|
||||
Reference in New Issue
Block a user