From a331eb2f118e0051c6c6744a20d6b0934c4d6d6f Mon Sep 17 00:00:00 2001 From: TheArcaneBrony Date: Wed, 28 Jun 2023 10:38:45 +0200 Subject: Update stuff --- MatrixRoomUtils.Core/Responses/LoginResponse.cs | 13 ------------- 1 file changed, 13 deletions(-) (limited to 'MatrixRoomUtils.Core/Responses') diff --git a/MatrixRoomUtils.Core/Responses/LoginResponse.cs b/MatrixRoomUtils.Core/Responses/LoginResponse.cs index 8d0d94f..b248739 100644 --- a/MatrixRoomUtils.Core/Responses/LoginResponse.cs +++ b/MatrixRoomUtils.Core/Responses/LoginResponse.cs @@ -1,7 +1,4 @@ -using System.Net.Http.Json; -using System.Text.Json; using System.Text.Json.Serialization; -using MatrixRoomUtils.Core.StateEventTypes; namespace MatrixRoomUtils.Core.Responses; @@ -17,14 +14,4 @@ public class LoginResponse { [JsonPropertyName("user_id")] public string UserId { get; set; } - - public async Task GetProfile() { - var hc = new HttpClient(); - var resp = await hc.GetAsync($"{HomeServer}/_matrix/client/v3/profile/{UserId}"); - var data = await resp.Content.ReadFromJsonAsync(); - if (!resp.IsSuccessStatusCode) Console.WriteLine("Profile: " + data); - return data.Deserialize(); - } - - public async Task GetCanonicalHomeserverUrl() => (await new RemoteHomeServer(HomeServer).Configure()).FullHomeServerDomain; } \ No newline at end of file -- cgit 1.5.1