aboutsummaryrefslogtreecommitdiff
path: root/syncapi/storage/sqlite3/receipt_table.go
diff options
context:
space:
mode:
Diffstat (limited to 'syncapi/storage/sqlite3/receipt_table.go')
-rw-r--r--syncapi/storage/sqlite3/receipt_table.go2
1 files changed, 1 insertions, 1 deletions
diff --git a/syncapi/storage/sqlite3/receipt_table.go b/syncapi/storage/sqlite3/receipt_table.go
index 69fc4e9d..6b39ee87 100644
--- a/syncapi/storage/sqlite3/receipt_table.go
+++ b/syncapi/storage/sqlite3/receipt_table.go
@@ -101,7 +101,7 @@ func (r *receiptStatements) UpsertReceipt(ctx context.Context, txn *sql.Tx, room
// SelectRoomReceiptsAfter select all receipts for a given room after a specific timestamp
func (r *receiptStatements) SelectRoomReceiptsAfter(ctx context.Context, roomIDs []string, streamPos types.StreamPosition) (types.StreamPosition, []api.OutputReceiptEvent, error) {
selectSQL := strings.Replace(selectRoomReceipts, "($2)", sqlutil.QueryVariadicOffset(len(roomIDs), 1), 1)
- lastPos := types.StreamPosition(0)
+ lastPos := streamPos
params := make([]interface{}, len(roomIDs)+1)
params[0] = streamPos
for k, v := range roomIDs {