Some fixes

pull/34714/head
Lunny Xiao 2025-06-13 11:36:09 -07:00
parent 3bc926b0c2
commit a2cb233132
No known key found for this signature in database
GPG Key ID: C3B7C91B632F738A
1 changed files with 2 additions and 2 deletions

View File

@ -151,7 +151,7 @@ func ForkPost(ctx *context.Context) {
ctx.Data["ContextUser"] = ctxUser
if ctx.HasError() {
ctx.JSONError(tplFork)
ctx.JSONError(ctx.GetErrMsg())
return
}
@ -184,7 +184,7 @@ func ForkPost(ctx *context.Context) {
ctx.ServerError("CanCreateOrgRepo", err)
return
} else if !isAllowedToFork {
ctx.JSONError(http.StatusForbidden)
ctx.HTTPError(http.StatusForbidden)
return
}
}