mirror of
https://github.com/go-gitea/gitea
synced 2025-08-11 12:08:21 +00:00
This commit is contained in:
@@ -508,7 +508,7 @@ func Delete(ctx *context.APIContext) {
|
||||
owner := ctx.Repo.Owner
|
||||
repo := ctx.Repo.Repository
|
||||
|
||||
if owner.IsOrganization() {
|
||||
if owner.IsOrganization() && !ctx.User.IsAdmin {
|
||||
isOwner, err := owner.IsOwnedBy(ctx.User.ID)
|
||||
if err != nil {
|
||||
ctx.Error(500, "IsOwnedBy", err)
|
||||
|
Reference in New Issue
Block a user