fix: adjust log middleware

This commit is contained in:
engigu
2024-01-02 18:08:52 +08:00
parent b6e3d2995a
commit 20750bc33a
5 changed files with 60 additions and 56 deletions
+1 -1
View File
@@ -68,7 +68,7 @@ func (cs *CronService) UpdateLogsCronRun(cron string) {
Job: ClearLogs,
})
logging.Logger.Error(fmt.Sprintf("更新日志的cron成功,%s", cron))
logging.Logger.Info(fmt.Sprintf("所有的定时任务: %s", TaskList))
logging.Logger.Error(fmt.Sprintf("所有的定时任务: %s", TaskList))
}
+1 -1
View File
@@ -36,7 +36,7 @@ func AddTask(task ScheduledTask) cron.EntryID {
logging.Logger.Error(fmt.Sprintf("添加定时任务失败,原因:%s", err))
} else {
TaskList[taskId] = &task
logging.Logger.Error(fmt.Sprintf("添加日志清除任务成功,entryID: %d, cron: %s", taskId, task.Schedule))
logging.Logger.Error(fmt.Sprintf("添加定时任务成功,entryID: %d, cron: %s", taskId, task.Schedule))
}
return taskId
}