diff options
author | kegsay <kegan@matrix.org> | 2023-04-21 17:06:29 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-04-21 17:06:29 +0100 |
commit | 1647213facae52e2c8889fbc848ffc5d3a5792f0 (patch) | |
tree | 684206b99582df20ae144e19db37591cc35b789d /userapi | |
parent | 71eeccf34a2ea4434c315c19778d80a7b2469270 (diff) |
Implement new RoomVersionImpl API (#3062)
As outlined in https://github.com/matrix-org/gomatrixserverlib/pull/368
The main change Dendrite side is that `RoomVersion` no longer has any
methods on it. Instead, you need to bounce via `gmsl.GetRoomVersion`.
It's very interesting to see where exactly Dendrite cares about this.
For some places it's creating events (fine) but others are way more
specific. Those areas will need to migrate to GMSL at some point.
Diffstat (limited to 'userapi')
-rw-r--r-- | userapi/consumers/roomserver_test.go | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/userapi/consumers/roomserver_test.go b/userapi/consumers/roomserver_test.go index 2ece0d58..465ec21a 100644 --- a/userapi/consumers/roomserver_test.go +++ b/userapi/consumers/roomserver_test.go @@ -36,7 +36,7 @@ func mustCreateDatabase(t *testing.T, dbType test.DBType) (storage.UserDatabase, func mustCreateEvent(t *testing.T, content string) *gomatrixserverlib.HeaderedEvent { t.Helper() - ev, err := gomatrixserverlib.RoomVersionV10.NewEventFromTrustedJSON([]byte(content), false) + ev, err := gomatrixserverlib.MustGetRoomVersion(gomatrixserverlib.RoomVersionV10).NewEventFromTrustedJSON([]byte(content), false) if err != nil { t.Fatalf("failed to create event: %v", err) } |