diff --git a/routers/private/hook.go b/routers/private/hook.go index 9f5579b6ae688..f93632515272a 100644 --- a/routers/private/hook.go +++ b/routers/private/hook.go @@ -392,11 +392,6 @@ func HookPreReceive(ctx *gitea_context.PrivateContext) { }) return } - } else { - log.Error("Unexpected ref: %s", refFullName) - ctx.JSON(http.StatusInternalServerError, private.Response{ - Err: fmt.Sprintf("Unexpected ref: %s", refFullName), - }) } }