mirror of
https://codeberg.org/forgejo/forgejo.git
synced 2024-09-10 20:22:14 +02:00
Fix ListUserOrgs (#12910)
fix #12891 Signed-off-by: a1012112796 <1012112796@qq.com> Co-authored-by: Lauris BH <lauris@nix.lv>
This commit is contained in:
parent
23f064e813
commit
b74ed16c41
1 changed files with 1 additions and 1 deletions
|
@ -85,7 +85,7 @@ func ListUserOrgs(ctx *context.APIContext) {
|
|||
if ctx.Written() {
|
||||
return
|
||||
}
|
||||
listUserOrgs(ctx, u, ctx.User.IsAdmin)
|
||||
listUserOrgs(ctx, u, ctx.User != nil && (ctx.User.IsAdmin || ctx.User.ID == u.ID))
|
||||
}
|
||||
|
||||
// GetAll return list of all public organizations
|
||||
|
|
Loading…
Reference in a new issue