chore(mobile): Add more error log (#2949)

Co-authored-by: alex <alex@pop-os.localdomain>
This commit is contained in:
Alex 2023-06-25 18:59:35 -05:00 committed by GitHub
parent a58482cb2b
commit b015648bfe
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 12 additions and 6 deletions

View file

@ -82,8 +82,12 @@ class AssetService {
_db.writeTxn(() => _db.eTags.put(ETag(id: user.id, value: newETag)));
}
return assets.map(Asset.remote).toList();
} catch (e, stack) {
log.severe('Error while getting remote assets', e, stack);
} catch (error, stack) {
log.severe(
'Error while getting remote assets: ${error.toString()}',
error,
stack,
);
return null;
}
}
@ -100,8 +104,8 @@ class AssetService {
return await _apiService.assetApi
.deleteAsset(DeleteAssetDto(ids: payload));
} catch (e) {
debugPrint("Error getAllAsset ${e.toString()}");
} catch (error, stack) {
log.severe("Error deleteAssets ${error.toString()}", error, stack);
return null;
}
}