diff options
Diffstat (limited to 'userapi/storage/accounts/postgres/account_data_table.go')
-rw-r--r-- | userapi/storage/accounts/postgres/account_data_table.go | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/userapi/storage/accounts/postgres/account_data_table.go b/userapi/storage/accounts/postgres/account_data_table.go index 90c79e87..09eb2611 100644 --- a/userapi/storage/accounts/postgres/account_data_table.go +++ b/userapi/storage/accounts/postgres/account_data_table.go @@ -20,6 +20,7 @@ import ( "encoding/json" "github.com/matrix-org/dendrite/internal" + "github.com/matrix-org/dendrite/internal/sqlutil" ) const accountDataSchema = ` @@ -75,7 +76,7 @@ func (s *accountDataStatements) prepare(db *sql.DB) (err error) { func (s *accountDataStatements) insertAccountData( ctx context.Context, txn *sql.Tx, localpart, roomID, dataType string, content json.RawMessage, ) (err error) { - stmt := txn.Stmt(s.insertAccountDataStmt) + stmt := sqlutil.TxStmt(txn, s.insertAccountDataStmt) _, err = stmt.ExecContext(ctx, localpart, roomID, dataType, content) return } |