Fix database locked

This commit is contained in:
Till Faelligen 2022-05-06 09:50:20 +02:00
parent 4d285fff60
commit 4bd9a73c13

View file

@ -140,7 +140,7 @@ func (s *accountsStatements) InsertAccount(
ctx context.Context, txn *sql.Tx, localpart, hash, appserviceID, policyVersion string, accountType api.AccountType, ctx context.Context, txn *sql.Tx, localpart, hash, appserviceID, policyVersion string, accountType api.AccountType,
) (*api.Account, error) { ) (*api.Account, error) {
createdTimeMS := time.Now().UnixNano() / 1000000 createdTimeMS := time.Now().UnixNano() / 1000000
stmt := s.insertAccountStmt stmt := sqlutil.TxStmt(txn, s.insertAccountStmt)
var err error var err error
if accountType != api.AccountTypeAppService { if accountType != api.AccountTypeAppService {