hide unavailable channels in webui

This commit is contained in:
lpf
2026-03-10 14:46:34 +08:00
parent 4a1b5f27e4
commit 594897c9bb
20 changed files with 110 additions and 30 deletions

View File

@@ -0,0 +1,30 @@
package channels
import "sort"
func CompiledChannelKeys() []string {
out := make([]string, 0, 7)
if telegramCompiled {
out = append(out, "telegram")
}
if whatsappCompiled {
out = append(out, "whatsapp")
}
if discordCompiled {
out = append(out, "discord")
}
if feishuCompiled {
out = append(out, "feishu")
}
if qqCompiled {
out = append(out, "qq")
}
if dingtalkCompiled {
out = append(out, "dingtalk")
}
if maixcamCompiled {
out = append(out, "maixcam")
}
sort.Strings(out)
return out
}