FIX callback query and BUTTON_DATA_INVALID error with hashStorage

This commit is contained in:
Hamidreza Ghavami
2023-05-20 20:29:28 +04:30
parent 4dfe527f20
commit 8c5648eb09
4 changed files with 172 additions and 47 deletions

View File

@@ -283,6 +283,9 @@ func (s *Server) startTask() {
return
}
// check for Telegram bot callback query hash storage reset
s.cron.AddJob("@every 2m", job.NewCheckHashStorageJob())
// Check CPU load and alarm to TgBot if threshold passes
cpuThreshold, err := s.settingService.GetTgCpu()
if (err == nil) && (cpuThreshold > 0) {