1
0
Fork 0
mirror of https://codeberg.org/forgejo/forgejo.git synced 2024-11-23 08:47:42 -05:00

Fix bug for ctx usage (#26763)

Fix #26684
Backport #26762

(cherry picked from commit a1cec4141e)
This commit is contained in:
Lunny Xiao 2023-08-28 12:20:31 +08:00 committed by Earl Warren
parent 66016b3fe3
commit bb84b7565f
No known key found for this signature in database
GPG key ID: 0579CB2928A78A00

View file

@ -334,9 +334,9 @@ func DismissApprovalReviews(ctx context.Context, doer *user_model.User, pull *is
return err return err
} }
return db.WithTx(ctx, func(subCtx context.Context) error { return db.WithTx(ctx, func(ctx context.Context) error {
for _, review := range reviews { for _, review := range reviews {
if err := issues_model.DismissReview(subCtx, review, true); err != nil { if err := issues_model.DismissReview(ctx, review, true); err != nil {
return err return err
} }