about summary refs log tree commit diff
path: root/LibMatrix/Helpers/SyncHelper.cs
diff options
context:
space:
mode:
authorTheArcaneBrony <myrainbowdash949@gmail.com>2023-09-04 02:17:10 +0200
committerTheArcaneBrony <myrainbowdash949@gmail.com>2023-09-04 02:17:10 +0200
commit21da6cde79ccd0cb7f895a29e3d8cab959ef11ba (patch)
treefb0b89566b64ae907d7ca3ea8a29adcf0c0361d0 /LibMatrix/Helpers/SyncHelper.cs
parentClean up some extension functions (diff)
downloadLibMatrix-21da6cde79ccd0cb7f895a29e3d8cab959ef11ba.tar.xz
Too many changes to name...
Diffstat (limited to '')
-rw-r--r--LibMatrix/Helpers/SyncHelper.cs15
1 files changed, 11 insertions, 4 deletions
diff --git a/LibMatrix/Helpers/SyncHelper.cs b/LibMatrix/Helpers/SyncHelper.cs
index b957c0c..de4f3d4 100644
--- a/LibMatrix/Helpers/SyncHelper.cs
+++ b/LibMatrix/Helpers/SyncHelper.cs
@@ -1,19 +1,26 @@
+using System;
+using System.Collections.Generic;
 using System.Diagnostics.CodeAnalysis;
+using System.Linq;
 using System.Net.Http.Json;
 using System.Text.Json.Serialization;
+using System.Threading;
+using System.Threading.Tasks;
+using ArcaneLibs.Extensions;
 using LibMatrix.Extensions;
 using LibMatrix.Filters;
+using LibMatrix.Homeservers;
 using LibMatrix.Responses;
 using LibMatrix.Services;
 
 namespace LibMatrix.Helpers;
 
 public class SyncHelper {
-    private readonly AuthenticatedHomeServer _homeServer;
+    private readonly AuthenticatedHomeserverGeneric _homeserver;
     private readonly TieredStorageService _storageService;
 
-    public SyncHelper(AuthenticatedHomeServer homeServer, TieredStorageService storageService) {
-        _homeServer = homeServer;
+    public SyncHelper(AuthenticatedHomeserverGeneric homeserver, TieredStorageService storageService) {
+        _homeserver = homeserver;
         _storageService = storageService;
     }
 
@@ -33,7 +40,7 @@ public class SyncHelper {
         // else url += "&full_state=true";
         Console.WriteLine("Calling: " + url);
         try {
-            var req = await _homeServer._httpClient.GetAsync(url, cancellationToken: cancellationToken ?? CancellationToken.None);
+            var req = await _homeserver._httpClient.GetAsync(url, cancellationToken: cancellationToken ?? CancellationToken.None);
 
             // var res = await JsonSerializer.DeserializeAsync<SyncResult>(await req.Content.ReadAsStreamAsync());