aboutsummaryrefslogtreecommitdiffstats
path: root/services/repository/files/content.go
diff options
context:
space:
mode:
Diffstat (limited to 'services/repository/files/content.go')
-rw-r--r--services/repository/files/content.go5
1 files changed, 2 insertions, 3 deletions
diff --git a/services/repository/files/content.go b/services/repository/files/content.go
index 95e7c7087c..0ab7422ce2 100644
--- a/services/repository/files/content.go
+++ b/services/repository/files/content.go
@@ -10,7 +10,6 @@ import (
"path"
"strings"
- "code.gitea.io/gitea/models"
repo_model "code.gitea.io/gitea/models/repo"
"code.gitea.io/gitea/modules/git"
"code.gitea.io/gitea/modules/gitrepo"
@@ -53,7 +52,7 @@ func GetContentsOrList(ctx context.Context, repo *repo_model.Repository, treePat
// Check that the path given in opts.treePath is valid (not a git path)
cleanTreePath := CleanUploadFileName(treePath)
if cleanTreePath == "" && treePath != "" {
- return nil, models.ErrFilenameInvalid{
+ return nil, ErrFilenameInvalid{
Path: treePath,
}
}
@@ -128,7 +127,7 @@ func GetContents(ctx context.Context, repo *repo_model.Repository, treePath, ref
// Check that the path given in opts.treePath is valid (not a git path)
cleanTreePath := CleanUploadFileName(treePath)
if cleanTreePath == "" && treePath != "" {
- return nil, models.ErrFilenameInvalid{
+ return nil, ErrFilenameInvalid{
Path: treePath,
}
}