aboutsummaryrefslogtreecommitdiffstats
path: root/routers/web/web.go
diff options
context:
space:
mode:
authorwxiaoguang <wxiaoguang@gmail.com>2023-05-11 16:25:46 +0800
committerGitHub <noreply@github.com>2023-05-11 08:25:46 +0000
commitf6e029e6c7849d4361abf7f1d749b5d528364ac4 (patch)
treeaf285dd000dc48e4e94e717cf61a8b2437e99beb /routers/web/web.go
parent58dfaf3a75a097088376a9c221784b3675ac9c48 (diff)
downloadgitea-f6e029e6c7849d4361abf7f1d749b5d528364ac4.tar.gz
gitea-f6e029e6c7849d4361abf7f1d749b5d528364ac4.zip
Make repo migration cancelable and fix various bugs (#24605)
Replace #12917 Close #24601 Close #12845 ![image](https://github.com/go-gitea/gitea/assets/2114189/39378118-064d-40fb-8396-4579ebf33917) ![image](https://github.com/go-gitea/gitea/assets/2114189/faf37418-191c-46a6-90a8-353141e00e2d) ![image](https://github.com/go-gitea/gitea/assets/2114189/fdc8ee4d-125f-4737-9990-89bcdf9eb388) ![image](https://github.com/go-gitea/gitea/assets/2114189/9a3bd2c2-fe20-4011-81f0-990ed869d139) --------- Co-authored-by: Yarden Shoham <git@yardenshoham.com> Co-authored-by: silverwind <me@silverwind.io> Co-authored-by: Giteabot <teabot@gitea.io>
Diffstat (limited to 'routers/web/web.go')
-rw-r--r--routers/web/web.go1
1 files changed, 1 insertions, 0 deletions
diff --git a/routers/web/web.go b/routers/web/web.go
index d0deb845fc..8784b7c5f7 100644
--- a/routers/web/web.go
+++ b/routers/web/web.go
@@ -939,6 +939,7 @@ func registerRoutes(m *web.Route) {
addSettingsRunnersRoutes()
addSettingsSecretsRoutes()
}, actions.MustEnableActions)
+ m.Post("/migrate/cancel", repo.MigrateCancelPost) // this handler must be under "settings", otherwise this incomplete repo can't be accessed
}, ctxDataSet("PageIsRepoSettings", true, "LFSStartServer", setting.LFS.StartServer))
}, reqSignIn, context.RepoAssignment, context.UnitTypes(), reqRepoAdmin, context.RepoRef())