add email notify enable/disable; remove (de)hyphening

hyphen/dehyphen conflicted with new migration for email contact
preference, and it's been a while since this has been an issue so i've
just commented it out for now.
This commit is contained in:
Harvey Tindall
2021-05-21 22:46:46 +01:00
parent 3bf722c5fe
commit a6447165b7
8 changed files with 229 additions and 175 deletions
+3 -1
View File
@@ -161,10 +161,12 @@ func (app *appContext) loadRoutes(router *gin.Engine) {
api.GET(p+"/config", app.GetConfig)
api.POST(p+"/config", app.ModifyConfig)
api.POST(p+"/restart", app.restart)
if telegramEnabled {
if telegramEnabled || discordEnabled {
api.GET(p+"/telegram/pin", app.TelegramGetPin)
api.GET(p+"/telegram/verified/:pin", app.TelegramVerified)
api.POST(p+"/users/telegram", app.TelegramAddUser)
}
if discordEnabled || telegramEnabled {
api.POST(p+"/users/contact", app.SetContactMethods)
}
if app.config.Section("ombi").Key("enabled").MustBool(false) {