aboutsummaryrefslogtreecommitdiffstats
path: root/services/repository/files/update.go
diff options
context:
space:
mode:
Diffstat (limited to 'services/repository/files/update.go')
-rw-r--r--services/repository/files/update.go3
1 files changed, 2 insertions, 1 deletions
diff --git a/services/repository/files/update.go b/services/repository/files/update.go
index 1892043304..f223daf3a9 100644
--- a/services/repository/files/update.go
+++ b/services/repository/files/update.go
@@ -16,6 +16,7 @@ import (
repo_model "code.gitea.io/gitea/models/repo"
user_model "code.gitea.io/gitea/models/user"
"code.gitea.io/gitea/modules/git"
+ "code.gitea.io/gitea/modules/gitrepo"
"code.gitea.io/gitea/modules/lfs"
"code.gitea.io/gitea/modules/log"
"code.gitea.io/gitea/modules/setting"
@@ -78,7 +79,7 @@ func ChangeRepoFiles(ctx context.Context, repo *repo_model.Repository, doer *use
opts.NewBranch = opts.OldBranch
}
- gitRepo, closer, err := git.RepositoryFromContextOrOpen(ctx, repo.RepoPath())
+ gitRepo, closer, err := gitrepo.RepositoryFromContextOrOpen(ctx, repo)
if err != nil {
return nil, err
}