diff options
Diffstat (limited to 'routers/api/v1/repo/fork.go')
-rw-r--r-- | routers/api/v1/repo/fork.go | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/routers/api/v1/repo/fork.go b/routers/api/v1/repo/fork.go index c743aec301..44b79a6fef 100644 --- a/routers/api/v1/repo/fork.go +++ b/routers/api/v1/repo/fork.go @@ -59,7 +59,7 @@ func CreateFork(ctx *context.APIContext, form api.CreateForkOption) { } else { org, err := models.GetOrgByName(*form.Organization) if err != nil { - if err == models.ErrOrgNotExist { + if models.IsErrOrgNotExist(err) { ctx.Error(422, "", err) } else { ctx.Error(500, "GetOrgByName", err) |