mirror of
https://github.com/matrix-org/dendrite
synced 2024-12-13 14:52:47 +00:00
Fix bug in error handling in SQLite InsertPreviousEvent (#1456)
This commit is contained in:
parent
fed3ebd2f1
commit
91fc1f1c92
1 changed files with 1 additions and 1 deletions
|
@ -98,7 +98,7 @@ func (s *previousEventStatements) InsertPreviousEvent(
|
|||
eventNIDAsString := fmt.Sprintf("%d", eventNID)
|
||||
selectStmt := sqlutil.TxStmt(txn, s.selectPreviousEventExistsStmt)
|
||||
err := selectStmt.QueryRowContext(ctx, previousEventID, previousEventReferenceSHA256).Scan(&eventNIDs)
|
||||
if err != sql.ErrNoRows {
|
||||
if err != nil && err != sql.ErrNoRows {
|
||||
return fmt.Errorf("selectStmt.QueryRowContext.Scan: %w", err)
|
||||
}
|
||||
var nids []string
|
||||
|
|
Loading…
Reference in a new issue