about summary refs log tree commit diff
path: root/MatrixRoomUtils.Web/Pages/HSAdmin
diff options
context:
space:
mode:
authorTheArcaneBrony <myrainbowdash949@gmail.com>2023-06-30 03:36:58 +0200
committerTheArcaneBrony <myrainbowdash949@gmail.com>2023-06-30 03:36:58 +0200
commitbb8c2637af3b7982e7a4b2fd15e2fbec613d0848 (patch)
treeb8075ba7e507aad3f96f354712ad920ac421e474 /MatrixRoomUtils.Web/Pages/HSAdmin
parentUpdate stuff (diff)
downloadMatrixUtils-bb8c2637af3b7982e7a4b2fd15e2fbec613d0848.tar.xz
Todays progress
Diffstat (limited to 'MatrixRoomUtils.Web/Pages/HSAdmin')
-rw-r--r--MatrixRoomUtils.Web/Pages/HSAdmin/RoomQuery.razor4
1 files changed, 3 insertions, 1 deletions
diff --git a/MatrixRoomUtils.Web/Pages/HSAdmin/RoomQuery.razor b/MatrixRoomUtils.Web/Pages/HSAdmin/RoomQuery.razor
index 858fad9..e3ebc72 100644
--- a/MatrixRoomUtils.Web/Pages/HSAdmin/RoomQuery.razor
+++ b/MatrixRoomUtils.Web/Pages/HSAdmin/RoomQuery.razor
@@ -165,7 +165,9 @@
 
     private async Task Search() {
         Results.Clear();
-        var searchRooms = RuntimeCache.CurrentHomeServer.Admin.SearchRoomsAsync(orderBy: OrderBy!, dir: Ascending ? "f" : "b", searchTerm: SearchTerm, localFilter: Filter).GetAsyncEnumerator();
+        var hs = await MRUStorage.GetCurrentSessionOrNavigate();
+        if (hs is null) return;
+        var searchRooms = hs.Admin.SearchRoomsAsync(orderBy: OrderBy!, dir: Ascending ? "f" : "b", searchTerm: SearchTerm, localFilter: Filter).GetAsyncEnumerator();
         while (await searchRooms.MoveNextAsync()) {
             var room = searchRooms.Current;
             Console.WriteLine("Hit: " + room.ToJson(false));