1
1
mirror of https://github.com/go-gitea/gitea synced 2025-07-22 02:08:36 +00:00

Allow site admin to check /api/v1/orgs endpoints (#10867)

Fix #9950

Signed-off-by: Andrew Thornton <art27@cantab.net>
This commit is contained in:
zeripath
2020-03-28 19:45:55 +00:00
committed by GitHub
parent 052bff0cff
commit 48890ce546
2 changed files with 2 additions and 2 deletions

View File

@@ -320,7 +320,7 @@ func GetTeamMembers(ctx *context.APIContext) {
if err != nil {
ctx.Error(http.StatusInternalServerError, "IsOrganizationMember", err)
return
} else if !isMember {
} else if !isMember && !ctx.User.IsAdmin {
ctx.NotFound()
return
}