diff options
Diffstat (limited to 'routers/web/user/setting/adopt.go')
-rw-r--r-- | routers/web/user/setting/adopt.go | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/routers/web/user/setting/adopt.go b/routers/web/user/setting/adopt.go index 2caccb69a5..948cc1e936 100644 --- a/routers/web/user/setting/adopt.go +++ b/routers/web/user/setting/adopt.go @@ -9,9 +9,9 @@ import ( "code.gitea.io/gitea/models" "code.gitea.io/gitea/modules/context" - "code.gitea.io/gitea/modules/repository" "code.gitea.io/gitea/modules/setting" "code.gitea.io/gitea/modules/util" + repo_service "code.gitea.io/gitea/services/repository" ) // AdoptOrDeleteRepository adopts or deletes a repository @@ -44,7 +44,7 @@ func AdoptOrDeleteRepository(ctx *context.Context) { if has || !isDir { // Fallthrough to failure mode } else if action == "adopt" && allowAdopt { - if _, err := repository.AdoptRepository(ctxUser, ctxUser, models.CreateRepoOptions{ + if _, err := repo_service.AdoptRepository(ctxUser, ctxUser, models.CreateRepoOptions{ Name: dir, IsPrivate: true, }); err != nil { @@ -53,7 +53,7 @@ func AdoptOrDeleteRepository(ctx *context.Context) { } ctx.Flash.Success(ctx.Tr("repo.adopt_preexisting_success", dir)) } else if action == "delete" && allowDelete { - if err := repository.DeleteUnadoptedRepository(ctxUser, ctxUser, dir); err != nil { + if err := repo_service.DeleteUnadoptedRepository(ctxUser, ctxUser, dir); err != nil { ctx.ServerError("repository.AdoptRepository", err) return } |