summaryrefslogtreecommitdiffstats
path: root/routers
diff options
context:
space:
mode:
authorGary Kim <gary@garykim.dev>2019-08-26 22:59:10 +0000
committertechknowlogick <techknowlogick@gitea.io>2019-08-26 18:59:10 -0400
commit541fab196f216771a51419a8b8d353694afa6c45 (patch)
treeec221139355ba7ea697c7a091a09dfb07398461a /routers
parentbb5f7cdae6276a2e48f106c3cf84ab7d2de74aa4 (diff)
downloadgitea-541fab196f216771a51419a8b8d353694afa6c45.tar.gz
gitea-541fab196f216771a51419a8b8d353694afa6c45.zip
Fix adding default Telegram webhook (#7972)
* Fix adding default Telegram webhook Fixes #7932 Signed-off-by: Gary Kim <gary@garykim.dev> * Run goimports Signed-off-by: Gary Kim <gary@garykim.dev>
Diffstat (limited to 'routers')
-rw-r--r--routers/routes/routes.go2
1 files changed, 2 insertions, 0 deletions
diff --git a/routers/routes/routes.go b/routers/routes/routes.go
index 8c329a5f6f..2afd0dcce9 100644
--- a/routers/routes/routes.go
+++ b/routers/routes/routes.go
@@ -446,6 +446,7 @@ func RegisterRoutes(m *macaron.Macaron) {
m.Post("/slack/new", bindIgnErr(auth.NewSlackHookForm{}), repo.SlackHooksNewPost)
m.Post("/discord/new", bindIgnErr(auth.NewDiscordHookForm{}), repo.DiscordHooksNewPost)
m.Post("/dingtalk/new", bindIgnErr(auth.NewDingtalkHookForm{}), repo.DingtalkHooksNewPost)
+ m.Post("/telegram/new", bindIgnErr(auth.NewTelegramHookForm{}), repo.TelegramHooksNewPost)
m.Post("/msteams/new", bindIgnErr(auth.NewMSTeamsHookForm{}), repo.MSTeamsHooksNewPost)
m.Get("/:id", repo.WebHooksEdit)
m.Post("/gitea/:id", bindIgnErr(auth.NewWebhookForm{}), repo.WebHooksEditPost)
@@ -453,6 +454,7 @@ func RegisterRoutes(m *macaron.Macaron) {
m.Post("/slack/:id", bindIgnErr(auth.NewSlackHookForm{}), repo.SlackHooksEditPost)
m.Post("/discord/:id", bindIgnErr(auth.NewDiscordHookForm{}), repo.DiscordHooksEditPost)
m.Post("/dingtalk/:id", bindIgnErr(auth.NewDingtalkHookForm{}), repo.DingtalkHooksEditPost)
+ m.Post("/telegram/:id", bindIgnErr(auth.NewTelegramHookForm{}), repo.TelegramHooksEditPost)
m.Post("/msteams/:id", bindIgnErr(auth.NewMSTeamsHookForm{}), repo.MSTeamsHooksNewPost)
})