diff --git a/mobile/lib/domain/utils/background_sync.dart b/mobile/lib/domain/utils/background_sync.dart index 39036952c4..9c3e6aa261 100644 --- a/mobile/lib/domain/utils/background_sync.dart +++ b/mobile/lib/domain/utils/background_sync.dart @@ -187,7 +187,7 @@ class BackgroundSyncManager { _syncWebsocketTask = _handleWsAssetEditReadyV1Batch(batchData); return _syncWebsocketTask!.whenComplete(() { _syncWebsocketTask = null; - }); + }).future; } Future syncLinkedAlbum() { @@ -227,7 +227,7 @@ CancellableTask _handleWsAssetUploadReadyV1Batch(List batchData) debugLabel: 'websocket-batch', ); -Cancelable _handleWsAssetEditReadyV1Batch(List batchData) => runInIsolateGentle( +CancellableTask _handleWsAssetEditReadyV1Batch(List batchData) => runInIsolateGentle( computation: (ref) => ref.read(syncStreamServiceProvider).handleWsAssetEditReadyV1Batch(batchData), debugLabel: 'websocket-edit', );