Skip to content

Commit

Permalink
Fix out-of-transaction query in removeOrgUser (go-gitea#4521)
Browse files Browse the repository at this point in the history
  • Loading branch information
SagePtr committed Jul 27, 2018
1 parent 40bbc73 commit e044dd9
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion models/org.go
Original file line number Diff line number Diff line change
Expand Up @@ -454,7 +454,7 @@ func AddOrgUser(orgID, uid int64) error {
func removeOrgUser(sess *xorm.Session, orgID, userID int64) error {
ou := new(OrgUser)

has, err := x.
has, err := sess.
Where("uid=?", userID).
And("org_id=?", orgID).
Get(ou)
Expand Down

0 comments on commit e044dd9

Please sign in to comment.