mirror of
https://codeberg.org/forgejo/forgejo.git
synced 2025-05-20 08:50:21 +00:00
Admin should be able to see all organizations
This is follow-up for 56c66ee486
allowing admin
to see private repositories, even when not being member of them.
This commit is contained in:
parent
ca96e04e5f
commit
e57b2dffa4
3 changed files with 11 additions and 5 deletions
|
@ -316,7 +316,7 @@ func showOrgProfile(ctx *middleware.Context) {
|
|||
org := ctx.Org.Organization
|
||||
ctx.Data["Title"] = org.FullName
|
||||
|
||||
repos, err := models.GetRepositories(org.Id, ctx.IsSigned && org.IsOrgMember(ctx.User.Id))
|
||||
repos, err := models.GetRepositories(org.Id, ctx.IsSigned && (ctx.User.IsAdmin || org.IsOrgMember(ctx.User.Id)))
|
||||
if err != nil {
|
||||
ctx.Handle(500, "GetRepositories", err)
|
||||
return
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue