diff options
author | Vivek Singh <vivek.singh@msystechnologies.com> | 2019-07-02 17:43:05 -0700 |
---|---|---|
committer | Vivek Singh <vivek.singh@msystechnologies.com> | 2019-07-02 17:43:05 -0700 |
commit | 4e864bb502c553d73c89b3667a6b9b3e8db1846a (patch) | |
tree | f8cfda7fc860a6ba196d199209d4c2ad8eed5cf8 /lib | |
parent | dae77fc75b5646490d9a69a5d36bf87326f18047 (diff) | |
download | chef-4e864bb502c553d73c89b3667a6b9b3e8db1846a.tar.gz |
Parse day param value into string
Signed-off-by: Vivek Singh <vivek.singh@msystechnologies.com>
Diffstat (limited to 'lib')
-rw-r--r-- | lib/chef/provider/windows_task.rb | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/chef/provider/windows_task.rb b/lib/chef/provider/windows_task.rb index 83347b764a..49f67d680d 100644 --- a/lib/chef/provider/windows_task.rb +++ b/lib/chef/provider/windows_task.rb @@ -446,7 +446,7 @@ class Chef def days_of_month days_of_month = [] if new_resource.day - days = new_resource.day.split(",") + days = new_resource.day.to_s.split(",") days.map! { |day| day.to_s.strip.upcase } days.delete("LAST") if days.include?("LAST") days.delete("LASTDAY") if days.include?("LASTDAY") @@ -466,7 +466,7 @@ class Chef if new_resource.day # this line of code is just to support backward compatibility of wild card * new_resource.day = "mon, tue, wed, thu, fri, sat, sun" if new_resource.day == "*" && new_resource.frequency == :weekly - days = new_resource.day.split(",") + days = new_resource.day.to_s.split(",") days.map! { |day| day.to_s.strip.upcase } weeks_days = get_binary_values_from_constants(days, DAYS_OF_WEEK) else |