add 修复wskey不会定时转换问题

This commit is contained in:
ZJY 2021-09-30 11:50:28 +08:00
parent 938770805c
commit 2b0a8f9a51

View File

@ -10,7 +10,7 @@ func intiSky() {
c := cron.New(cron.WithSeconds()) //精确到秒
//定时任务
spec := "0 0 " + Config.CTime + "/12 * * ?" //cron表达式每秒一次
spec := "0 0" + " " + Config.CTime + "/12 * * ?" //cron表达式每秒一次
logs.Info(spec)
if Config.Wskey {
c.AddFunc(spec, func() {