Move prev_batch calculation (#2856)

This might help #2847.
This commit is contained in:
Neil Alexander 2022-11-03 16:56:21 +00:00 committed by GitHub
parent fb2e7d1b05
commit 98d3f88bfb
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
3 changed files with 29 additions and 28 deletions

View file

@ -259,7 +259,7 @@ func (d *DatabaseTransaction) StreamToTopologicalPosition(
// oldest event in the room's topology.
func (d *DatabaseTransaction) GetBackwardTopologyPos(
ctx context.Context,
events []types.StreamEvent,
events []*gomatrixserverlib.HeaderedEvent,
) (types.TopologyToken, error) {
zeroToken := types.TopologyToken{}
if len(events) == 0 {