diff options
author | Pete Higgins <pete@peterhiggins.org> | 2020-06-16 15:54:35 -0700 |
---|---|---|
committer | Pete Higgins <pete@peterhiggins.org> | 2020-06-16 15:54:35 -0700 |
commit | faed9973a24d8b35ffeda78d688831e185fc9163 (patch) | |
tree | 0259f0cdf872ada94bb5c0d26dc55f97f769461c | |
parent | 1d7a668841a51f6d46544205d126b83b8d4bdb27 (diff) | |
download | chef-faed9973a24d8b35ffeda78d688831e185fc9163.tar.gz |
Change a variable name causing a spelling violation.
Signed-off-by: Pete Higgins <pete@peterhiggins.org>
-rw-r--r-- | lib/chef/resource/cron/_cron_shared.rb | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/lib/chef/resource/cron/_cron_shared.rb b/lib/chef/resource/cron/_cron_shared.rb index 13df4b83f3..2f6a116a05 100644 --- a/lib/chef/resource/cron/_cron_shared.rb +++ b/lib/chef/resource/cron/_cron_shared.rb @@ -33,7 +33,7 @@ property :month, [Integer, String], property :weekday, [Integer, String, Symbol], description: "The day of the week on which this entry is to run (`0-7`, `mon-sun`, `monday-sunday`, or `*`), where Sunday is both `0` and `7`.", - default: "*", coerce: proc { |wday| weekday_in_crontab(wday) }, + default: "*", coerce: proc { |day| weekday_in_crontab(day) }, callbacks: { "should be a valid weekday spec" => ->(spec) { Chef::ResourceHelpers::CronValidations.validate_dow(spec) }, } @@ -92,7 +92,7 @@ private # Convert weekday input value into crontab format that # could be written in the crontab # @return [Integer, String] A weekday formed as per the user inputs. -def weekday_in_crontab(wday) - weekday = wday.to_s.downcase.to_sym - WEEKDAYS[weekday] || wday -end
\ No newline at end of file +def weekday_in_crontab(day) + weekday = day.to_s.downcase.to_sym + WEEKDAYS[weekday] || day +end |