diff options
author | Till <2353100+S7evinK@users.noreply.github.com> | 2023-02-24 09:40:20 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-02-24 09:40:20 +0100 |
commit | ad07b169b8a58b5a843b7b19ff0a989399d0aea0 (patch) | |
tree | 8904e5e52ecec90aa94f748c10a08b08cdf01de1 /roomserver/internal/query/query_test.go | |
parent | e6aa0955ff4113114ff8f30073582cc4ecc454fa (diff) |
Refactor `StoreEvent` and create a new `RoomDatabase` interface (#2985)
This PR changes a few things:
- It pulls out the creation of several NIDs from the `StoreEvent`
function to make the functions more reusable
- Uses more caching when using those NIDs to avoid DB round trips
Diffstat (limited to 'roomserver/internal/query/query_test.go')
-rw-r--r-- | roomserver/internal/query/query_test.go | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/roomserver/internal/query/query_test.go b/roomserver/internal/query/query_test.go index 03627ea9..16761157 100644 --- a/roomserver/internal/query/query_test.go +++ b/roomserver/internal/query/query_test.go @@ -80,7 +80,7 @@ func (db *getEventDB) addFakeEvents(graph map[string][]string) error { } // EventsFromIDs implements RoomserverInternalAPIEventDB -func (db *getEventDB) EventsFromIDs(ctx context.Context, eventIDs []string) (res []types.Event, err error) { +func (db *getEventDB) EventsFromIDs(ctx context.Context, roomNID types.RoomNID, eventIDs []string) (res []types.Event, err error) { for _, evID := range eventIDs { res = append(res, types.Event{ EventNID: 0, |