This commit is contained in:
parent
7bc1faabdb
commit
c1275e2ba6
1 changed files with 1 additions and 1 deletions
|
@ -508,7 +508,7 @@ func Delete(ctx *context.APIContext) {
|
||||||
owner := ctx.Repo.Owner
|
owner := ctx.Repo.Owner
|
||||||
repo := ctx.Repo.Repository
|
repo := ctx.Repo.Repository
|
||||||
|
|
||||||
if owner.IsOrganization() {
|
if owner.IsOrganization() && !ctx.User.IsAdmin {
|
||||||
isOwner, err := owner.IsOwnedBy(ctx.User.ID)
|
isOwner, err := owner.IsOwnedBy(ctx.User.ID)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
ctx.Error(500, "IsOwnedBy", err)
|
ctx.Error(500, "IsOwnedBy", err)
|
||||||
|
|
Reference in a new issue