0

[WIP] for SendGoodMorning make sense to iterate over chats only, introduce one more slice for it

* Change mechanics of SendGoodMorning
* Allocate one more slice chatGroupList to store groups/supergroups/channels
* Update TODO.org
This commit is contained in:
eleksir
2025-11-04 22:22:25 +03:00
parent 5471e09a24
commit af7ff57279
4 changed files with 34 additions and 10 deletions

View File

@@ -31,7 +31,7 @@ var (
// SendGoodMorning отсылает сообщение "с добрым утром" (сейчас - фортунку). Предполагается, что оно прогоняется по
// всем желающим чатам раз в сутки, с утра. Утро отсчитывается от настроек локали в системе.
SendGoodMorning = func() {
for _, chatID := range chatList {
for _, chatID := range chatGroupList {
if GetSetting(chatID, "FortuneMsg") == "1" {
me, err := tg.GetMe()
// Засылаем фразу в misc-канал (в роутер).