Skip to content

Commit

Permalink
Pass Context during exec in create. (#688)
Browse files Browse the repository at this point in the history
  • Loading branch information
martinei committed Feb 14, 2022
1 parent d148b95 commit f7abee9
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion dialect_common.go
Expand Up @@ -85,7 +85,7 @@ func genericCreate(s store, model *Model, cols columns.Columns, quoter quotable)
if err != nil {
return err
}
_, err = stmt.Exec(model.Value)
_, err = stmt.ExecContext(model.ctx, model.Value)
if err != nil {
if closeErr := stmt.Close(); closeErr != nil {
return fmt.Errorf("failed to close prepared statement: %s: %w", closeErr, err)
Expand Down

0 comments on commit f7abee9

Please sign in to comment.