mirror of
https://github.com/matrix-org/sliding-sync.git
synced 2025-03-10 13:37:11 +00:00
Apply suggestions from code review
Co-authored-by: David Robertson <davidr@element.io>
This commit is contained in:
parent
38f9cd0de8
commit
8f2e0697f6
@ -96,7 +96,7 @@ func (t *ReceiptTable) SelectReceiptsForEvents(roomID string, eventIDs []string)
|
||||
return
|
||||
}
|
||||
|
||||
// Select all (including private) receipts for this user in this room.
|
||||
// Select all (including private) receipts for this user in these rooms.
|
||||
func (t *ReceiptTable) SelectReceiptsForUser(roomIDs []string, userID string) (receiptsByRoom map[string][]internal.Receipt, err error) {
|
||||
var receipts []internal.Receipt
|
||||
err = t.db.Select(&receipts, `SELECT room_id, event_id, user_id, ts, thread_id FROM syncv3_receipts
|
||||
|
@ -118,7 +118,7 @@ func (r *ReceiptsRequest) ProcessInitial(ctx context.Context, res *Response, ext
|
||||
if len(receipts) == 0 {
|
||||
continue
|
||||
}
|
||||
rooms[roomID], _ = state.PackReceiptsIntoEDU(append(receipts, receipts...))
|
||||
rooms[roomID], _ = state.PackReceiptsIntoEDU(receipts)
|
||||
}
|
||||
|
||||
if len(rooms) > 0 {
|
||||
|
Loading…
x
Reference in New Issue
Block a user