mirror of
https://gitee.com/gitea/gitea
synced 2025-11-04 00:20:25 +08:00
Refactor HTTP request context (#17979)
This commit is contained in:
@@ -17,12 +17,12 @@ import (
|
||||
// Restart causes the server to perform a graceful restart
|
||||
func Restart(ctx *context.PrivateContext) {
|
||||
graceful.GetManager().DoGracefulRestart()
|
||||
ctx.PlainText(http.StatusOK, []byte("success"))
|
||||
ctx.PlainText(http.StatusOK, "success")
|
||||
|
||||
}
|
||||
|
||||
// Shutdown causes the server to perform a graceful shutdown
|
||||
func Shutdown(ctx *context.PrivateContext) {
|
||||
graceful.GetManager().DoGracefulShutdown()
|
||||
ctx.PlainText(http.StatusOK, []byte("success"))
|
||||
ctx.PlainText(http.StatusOK, "success")
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user