mirror of
https://github.com/matrix-org/dendrite.git
synced 2025-12-20 05:13:11 -06:00
Handle nil txn
This commit is contained in:
parent
8c1a112fb6
commit
a420a4f072
|
|
@ -109,7 +109,7 @@ func (s *inviteStatements) UpdateInviteRetired(
|
||||||
txn *sql.Tx, roomNID types.RoomNID, targetUserNID types.EventStateKeyNID,
|
txn *sql.Tx, roomNID types.RoomNID, targetUserNID types.EventStateKeyNID,
|
||||||
) (eventIDs []string, err error) {
|
) (eventIDs []string, err error) {
|
||||||
// gather all the event IDs we will retire
|
// gather all the event IDs we will retire
|
||||||
stmt := txn.Stmt(s.selectInvitesAboutToRetireStmt)
|
stmt := internal.TxStmt(txn, s.selectInvitesAboutToRetireStmt)
|
||||||
rows, err := stmt.QueryContext(ctx, roomNID, targetUserNID)
|
rows, err := stmt.QueryContext(ctx, roomNID, targetUserNID)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return nil, err
|
return nil, err
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue