asynchronously send event notification

This commit is contained in:
Akulij 2025-03-29 19:34:18 +08:00
parent 5923f6bf3f
commit bf1d7df88f

View File

@ -88,8 +88,10 @@ func notifyAboutEvents(bc BotController) {
for _, reservation := range reservations {
uid := reservation.UserID
msg := tgbotapi.NewMessage(uid, bc.GetBotContent("notify_pre_event"))
bc.bot.Send(msg)
go func() {
msg := tgbotapi.NewMessage(uid, bc.GetBotContent("notify_pre_event"))
bc.bot.Send(msg)
}()
}
}
}