From def33cc092ae2c6defcc218b108b7c99cbfb8581 Mon Sep 17 00:00:00 2001 From: TheArcaneBrony Date: Sun, 2 Jul 2023 01:01:09 +0200 Subject: Prefetch room info --- .../Classes/RoomCreationTemplates/DefaultRoomCreationTemplate.cs | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) (limited to 'MatrixRoomUtils.Web/Classes/RoomCreationTemplates') diff --git a/MatrixRoomUtils.Web/Classes/RoomCreationTemplates/DefaultRoomCreationTemplate.cs b/MatrixRoomUtils.Web/Classes/RoomCreationTemplates/DefaultRoomCreationTemplate.cs index ca6345f..a519977 100644 --- a/MatrixRoomUtils.Web/Classes/RoomCreationTemplates/DefaultRoomCreationTemplate.cs +++ b/MatrixRoomUtils.Web/Classes/RoomCreationTemplates/DefaultRoomCreationTemplate.cs @@ -2,6 +2,7 @@ using System.Text.Json.Nodes; using MatrixRoomUtils.Core; using MatrixRoomUtils.Core.Responses; using MatrixRoomUtils.Core.StateEventTypes; +using MatrixRoomUtils.Core.StateEventTypes.Spec; namespace MatrixRoomUtils.Web.Classes.RoomCreationTemplates; @@ -9,7 +10,7 @@ public class DefaultRoomCreationTemplate : IRoomCreationTemplate { public string Name => "Default"; public CreateRoomRequest CreateRoomRequest => - new CreateRoomRequest { + new() { Name = "My new room", RoomAliasName = "myroom", InitialState = new List { @@ -21,7 +22,7 @@ public class DefaultRoomCreationTemplate : IRoomCreationTemplate { }, new() { Type = "m.room.guest_access", - TypedContent = new GuestAccessData { + TypedContent = new GuestAccessEventData { GuestAccess = "can_join" } }, @@ -47,7 +48,7 @@ public class DefaultRoomCreationTemplate : IRoomCreationTemplate { } }, Visibility = "public", - PowerLevelContentOverride = new PowerLevelEvent { + PowerLevelContentOverride = new PowerLevelEventData { UsersDefault = 0, EventsDefault = 100, StateDefault = 50, @@ -55,7 +56,7 @@ public class DefaultRoomCreationTemplate : IRoomCreationTemplate { Redact = 50, Kick = 50, Ban = 50, - NotificationsPl = new PowerLevelEvent.NotificationsPL { + NotificationsPl = new PowerLevelEventData.NotificationsPL { Room = 50 }, Events = new Dictionary { -- cgit 1.5.1