diff --git a/monitors/monitorHelper.go b/monitors/monitorHelper.go index ff78aec..aaf9a20 100644 --- a/monitors/monitorHelper.go +++ b/monitors/monitorHelper.go @@ -12,7 +12,9 @@ type MonitorHelper struct { func (the *MonitorHelper) initial() { the.Cron = cron.New() - log.Printf("cronStr=%s", the.CronStr) + if the.CronStr != "" { + log.Printf("cronStr=%s", the.CronStr) + } } // RegisterTask 注册定时器方法