diff options
Diffstat (limited to 'routers/api/v1/repo/tree.go')
-rw-r--r-- | routers/api/v1/repo/tree.go | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/routers/api/v1/repo/tree.go b/routers/api/v1/repo/tree.go index aec336235d..2168a311d0 100644 --- a/routers/api/v1/repo/tree.go +++ b/routers/api/v1/repo/tree.go @@ -8,7 +8,7 @@ import ( "net/http" "code.gitea.io/gitea/modules/context" - "code.gitea.io/gitea/modules/repofiles" + files_service "code.gitea.io/gitea/services/repository/files" ) // GetTree get the tree of a repository. @@ -60,7 +60,7 @@ func GetTree(ctx *context.APIContext) { ctx.Error(http.StatusBadRequest, "", "sha not provided") return } - if tree, err := repofiles.GetTreeBySHA(ctx.Repo.Repository, sha, ctx.FormInt("page"), ctx.FormInt("per_page"), ctx.FormBool("recursive")); err != nil { + if tree, err := files_service.GetTreeBySHA(ctx.Repo.Repository, sha, ctx.FormInt("page"), ctx.FormInt("per_page"), ctx.FormBool("recursive")); err != nil { ctx.Error(http.StatusBadRequest, "", err.Error()) } else { ctx.JSON(http.StatusOK, tree) |