We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 697213b commit b88dbe1Copy full SHA for b88dbe1
models/user.go
@@ -1619,14 +1619,7 @@ func (opts *SearchUserOptions) toConds() builder.Cond {
1619
}
1620
1621
if opts.Actor != nil {
1622
- var exprCond builder.Cond
1623
- if setting.Database.UseMySQL {
1624
- exprCond = builder.Expr("org_user.org_id = user.id")
1625
- } else if setting.Database.UseMSSQL {
1626
- exprCond = builder.Expr("org_user.org_id = [user].id")
1627
- } else {
1628
- exprCond = builder.Expr("org_user.org_id = \"user\".id")
1629
- }
+ var exprCond builder.Cond = builder.Expr("org_user.org_id = `user`.id")
1630
1631
// If Admin - they see all users!
1632
if !opts.Actor.IsAdmin {
0 commit comments