summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTim Smith <tsmith@chef.io>2020-06-16 16:39:01 -0700
committerGitHub <noreply@github.com>2020-06-16 16:39:01 -0700
commit8415abfd29efa28f106bf7e43cde00268b3222f9 (patch)
tree0259f0cdf872ada94bb5c0d26dc55f97f769461c
parent1d7a668841a51f6d46544205d126b83b8d4bdb27 (diff)
parentfaed9973a24d8b35ffeda78d688831e185fc9163 (diff)
downloadchef-8415abfd29efa28f106bf7e43cde00268b3222f9.tar.gz
Merge pull request #10004 from chef/fix-spelling-violation
Change a variable name causing a spelling violation.
-rw-r--r--lib/chef/resource/cron/_cron_shared.rb10
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