about summary refs log tree commit diff
path: root/MatrixRoomUtils.Core/AuthenticatedHomeServer.cs
diff options
context:
space:
mode:
authorTheArcaneBrony <myrainbowdash949@gmail.com>2023-06-28 10:38:45 +0200
committerTheArcaneBrony <myrainbowdash949@gmail.com>2023-06-28 10:38:45 +0200
commita331eb2f118e0051c6c6744a20d6b0934c4d6d6f (patch)
treea7798d94a3553106aad40507e2dc04ff9d2f9efd /MatrixRoomUtils.Core/AuthenticatedHomeServer.cs
parentDependency injection stuff (diff)
downloadMatrixUtils-a331eb2f118e0051c6c6744a20d6b0934c4d6d6f.tar.xz
Update stuff
Diffstat (limited to 'MatrixRoomUtils.Core/AuthenticatedHomeServer.cs')
-rw-r--r--MatrixRoomUtils.Core/AuthenticatedHomeServer.cs10
1 files changed, 0 insertions, 10 deletions
diff --git a/MatrixRoomUtils.Core/AuthenticatedHomeServer.cs b/MatrixRoomUtils.Core/AuthenticatedHomeServer.cs
index b7e01dd..10bbb36 100644
--- a/MatrixRoomUtils.Core/AuthenticatedHomeServer.cs
+++ b/MatrixRoomUtils.Core/AuthenticatedHomeServer.cs
@@ -31,16 +31,6 @@ public class AuthenticatedHomeServer : IHomeServer {
     public string UserId { get; }
     public string AccessToken { get; set; }
 
-    public async Task<AuthenticatedHomeServer> Configure() {
-        FullHomeServerDomain = await ResolveHomeserverFromWellKnown(HomeServerDomain);
-        _httpClient.Dispose();
-        _httpClient = new MatrixHttpClient { BaseAddress = new Uri(FullHomeServerDomain) };
-        _httpClient.DefaultRequestHeaders.Authorization = new AuthenticationHeaderValue("Bearer", AccessToken);
-        Console.WriteLine("[AHS] Finished setting up http client");
-        WhoAmI = (await _httpClient.GetFromJsonAsync<WhoAmIResponse>("/_matrix/client/v3/account/whoami"))!;
-
-        return this;
-    }
 
     public async Task<GenericRoom> GetRoom(string roomId) => new(this, roomId);