aboutsummaryrefslogtreecommitdiffstats
path: root/routers/web/repo/patch.go
diff options
context:
space:
mode:
Diffstat (limited to 'routers/web/repo/patch.go')
-rw-r--r--routers/web/repo/patch.go3
1 files changed, 1 insertions, 2 deletions
diff --git a/routers/web/repo/patch.go b/routers/web/repo/patch.go
index 0dee02dd9c..5906ec6f3d 100644
--- a/routers/web/repo/patch.go
+++ b/routers/web/repo/patch.go
@@ -6,7 +6,6 @@ package repo
import (
"strings"
- "code.gitea.io/gitea/models"
git_model "code.gitea.io/gitea/models/git"
"code.gitea.io/gitea/models/unit"
"code.gitea.io/gitea/modules/base"
@@ -101,7 +100,7 @@ func NewDiffPatchPost(ctx *context.Context) {
ctx.Data["Err_NewBranchName"] = true
ctx.RenderWithErr(ctx.Tr("repo.editor.branch_already_exists", branchErr.BranchName), tplEditFile, &form)
return
- } else if models.IsErrCommitIDDoesNotMatch(err) {
+ } else if files.IsErrCommitIDDoesNotMatch(err) {
ctx.RenderWithErr(ctx.Tr("repo.editor.file_changed_while_editing", ctx.Repo.RepoLink+"/compare/"+form.LastCommit+"..."+ctx.Repo.CommitID), tplPatchFile, &form)
return
}