about summary refs log tree commit diff
path: root/Tests/LibMatrix.HomeserverEmulator/Controllers/Rooms/RoomStateController.cs
diff options
context:
space:
mode:
authorRory& <root@rory.gay>2024-05-30 08:02:40 +0000
committerRory& <root@rory.gay>2024-05-30 08:02:40 +0000
commitae18c049338dfcb33f721eeeb0a05571e8bd87a9 (patch)
tree9e73ae6a42a310efe43c6a9ed7d13ce19e0cbde5 /Tests/LibMatrix.HomeserverEmulator/Controllers/Rooms/RoomStateController.cs
parentLog warning if registering a duplicate type (diff)
downloadLibMatrix-bak-ae18c049338dfcb33f721eeeb0a05571e8bd87a9.tar.xz
Rename StateEvent to LegacyMatrixEvent
Diffstat (limited to 'Tests/LibMatrix.HomeserverEmulator/Controllers/Rooms/RoomStateController.cs')
-rw-r--r--Tests/LibMatrix.HomeserverEmulator/Controllers/Rooms/RoomStateController.cs4
1 files changed, 2 insertions, 2 deletions
diff --git a/Tests/LibMatrix.HomeserverEmulator/Controllers/Rooms/RoomStateController.cs b/Tests/LibMatrix.HomeserverEmulator/Controllers/Rooms/RoomStateController.cs

index 74c70a3..dfe119f 100644 --- a/Tests/LibMatrix.HomeserverEmulator/Controllers/Rooms/RoomStateController.cs +++ b/Tests/LibMatrix.HomeserverEmulator/Controllers/Rooms/RoomStateController.cs
@@ -10,7 +10,7 @@ namespace LibMatrix.HomeserverEmulator.Controllers.Rooms; [Route("/_matrix/client/{version}/rooms/{roomId}/state")] public class RoomStateController(ILogger<RoomStateController> logger, TokenService tokenService, UserStore userStore, RoomStore roomStore) : ControllerBase { [HttpGet("")] - public async Task<FrozenSet<StateEventResponse>> GetState(string roomId) { + public async Task<FrozenSet<LegacyMatrixEventResponse>> GetState(string roomId) { var token = tokenService.GetAccessTokenOrNull(HttpContext); if (token == null) throw new MatrixException() { @@ -103,7 +103,7 @@ public class RoomStateController(ILogger<RoomStateController> logger, TokenServi ErrorCode = "M_NOT_FOUND", Error = "Room not found" }; - var evt = room.SetStateInternal(new StateEvent() { Type = eventType, StateKey = stateKey, RawContent = request }.ToStateEvent(user, room)); + var evt = room.SetStateInternal(new LegacyMatrixEvent() { Type = eventType, StateKey = stateKey, RawContent = request }.ToStateEvent(user, room)); evt.Type = eventType; evt.StateKey = stateKey; return new EventIdResponse() {