diff options
author | Lunny Xiao <xiaolunwen@gmail.com> | 2023-08-05 10:40:27 +0800 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-08-05 10:40:27 +0800 |
commit | 12c249c5ca3d719850831c113ec1998d2124b860 (patch) | |
tree | f45310cd40dcce930aafe77af99bed5044aab582 /models/issues/issue_user.go | |
parent | e5011a0e6d74071adfa17fd806234fd9108cb867 (diff) | |
download | gitea-12c249c5ca3d719850831c113ec1998d2124b860.tar.gz gitea-12c249c5ca3d719850831c113ec1998d2124b860.zip |
Fix bug with sqlite load read (#26305)
Possible fix #26280
Diffstat (limited to 'models/issues/issue_user.go')
-rw-r--r-- | models/issues/issue_user.go | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/models/issues/issue_user.go b/models/issues/issue_user.go index 47da5c62c4..d053b1d543 100644 --- a/models/issues/issue_user.go +++ b/models/issues/issue_user.go @@ -55,8 +55,8 @@ func NewIssueUsers(ctx context.Context, repo *repo_model.Repository, issue *Issu } // UpdateIssueUserByRead updates issue-user relation for reading. -func UpdateIssueUserByRead(uid, issueID int64) error { - _, err := db.GetEngine(db.DefaultContext).Exec("UPDATE `issue_user` SET is_read=? WHERE uid=? AND issue_id=?", true, uid, issueID) +func UpdateIssueUserByRead(ctx context.Context, uid, issueID int64) error { + _, err := db.GetEngine(ctx).Exec("UPDATE `issue_user` SET is_read=? WHERE uid=? AND issue_id=?", true, uid, issueID) return err } |