mirror of
https://codeberg.org/forgejo/forgejo.git
synced 2024-12-28 14:43:52 +03:00
Fix missed return (#29450)
(cherry picked from commit e9f4c2db8291c54044345aebd9381ac820ed9687)
This commit is contained in:
parent
15660334ba
commit
c498c07adf
1 changed files with 1 additions and 0 deletions
|
@ -672,6 +672,7 @@ func UpdateFile(ctx *context.APIContext) {
|
||||||
apiOpts := web.GetForm(ctx).(*api.UpdateFileOptions)
|
apiOpts := web.GetForm(ctx).(*api.UpdateFileOptions)
|
||||||
if ctx.Repo.Repository.IsEmpty {
|
if ctx.Repo.Repository.IsEmpty {
|
||||||
ctx.Error(http.StatusUnprocessableEntity, "RepoIsEmpty", fmt.Errorf("repo is empty"))
|
ctx.Error(http.StatusUnprocessableEntity, "RepoIsEmpty", fmt.Errorf("repo is empty"))
|
||||||
|
return
|
||||||
}
|
}
|
||||||
|
|
||||||
if apiOpts.BranchName == "" {
|
if apiOpts.BranchName == "" {
|
||||||
|
|
Loading…
Reference in a new issue