From ad51512971643ccc64735c07246a99804078209d Mon Sep 17 00:00:00 2001 From: Lingfei Kong Date: Thu, 21 Jul 2022 23:35:44 +0800 Subject: [PATCH] refactor: optimize variable name crontab to cronjob --- internal/watcher/watcher.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/internal/watcher/watcher.go b/internal/watcher/watcher.go index 7198ed6f..564c2804 100644 --- a/internal/watcher/watcher.go +++ b/internal/watcher/watcher.go @@ -41,13 +41,13 @@ func newWatchJob(redisOptions *genericoptions.RedisOptions, watcherOptions *opti rs := redsync.New(goredis.NewPool(client)) - crontab := cron.New( + cronjob := cron.New( cron.WithSeconds(), cron.WithChain(cron.SkipIfStillRunning(logger), cron.Recover(logger)), ) return &watchJob{ - Cron: crontab, + Cron: cronjob, config: watcherOptions, rs: rs, }