about summary refs log tree commit diff
path: root/LibMatrix/Helpers/SyncHelper.cs
diff options
context:
space:
mode:
Diffstat (limited to 'LibMatrix/Helpers/SyncHelper.cs')
-rw-r--r--LibMatrix/Helpers/SyncHelper.cs5
1 files changed, 2 insertions, 3 deletions
diff --git a/LibMatrix/Helpers/SyncHelper.cs b/LibMatrix/Helpers/SyncHelper.cs
index 2015eaa..b957c0c 100644
--- a/LibMatrix/Helpers/SyncHelper.cs
+++ b/LibMatrix/Helpers/SyncHelper.cs
@@ -76,10 +76,9 @@ public class SyncHelper {
             .Where(x => x.StartsWith("sync"))
             .ToList()
             .Select(x => _storageService.CacheStorageProvider.DeleteObjectAsync(x)));
-        SyncResult? sync = null;
-        string? nextBatch = since;
+        var nextBatch = since;
         while (cancellationToken is null || !cancellationToken.Value.IsCancellationRequested) {
-            sync = await Sync(since: nextBatch, timeout: timeout, setPresence: setPresence, filter: filter,
+            var sync = await Sync(since: nextBatch, timeout: timeout, setPresence: setPresence, filter: filter,
                 cancellationToken: cancellationToken);
             nextBatch = sync?.NextBatch ?? nextBatch;
             if (sync is null) continue;