diff options
Diffstat (limited to 'lib/chef/mixin/create_path.rb')
-rw-r--r-- | lib/chef/mixin/create_path.rb | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/chef/mixin/create_path.rb b/lib/chef/mixin/create_path.rb index 455110b1a2..78cf71af0b 100644 --- a/lib/chef/mixin/create_path.rb +++ b/lib/chef/mixin/create_path.rb @@ -29,11 +29,11 @@ class Chef # === Returns # The created file_path. def create_path(file_path) - unless file_path.kind_of?(String) || file_path.kind_of?(Array) + unless file_path.is_a?(String) || file_path.is_a?(Array) raise ArgumentError, "file_path must be a string or an array!" end - if file_path.kind_of?(String) + if file_path.is_a?(String) file_path = File.expand_path(file_path).split(File::SEPARATOR) file_path.shift if file_path[0] == "" # Check if path starts with a separator or drive letter (Windows) |