diff options
author | Tim Smith <tsmith@chef.io> | 2017-11-03 10:15:22 -0700 |
---|---|---|
committer | Tim Smith <tsmith@chef.io> | 2017-11-03 10:15:22 -0700 |
commit | 82ae35719c99c5cbfa9888c9645c525950c08cba (patch) | |
tree | f1ffc5c09f4b647599e4a99e5f62dae3d2c08eab | |
parent | 7f0b5150c32994b4ad593505172c5834a984b087 (diff) | |
download | chef-spec_warning.tar.gz |
Dir.exists? -> Dir.exist? to avoid warning in rspecspec_warning
Avoids several annoying lines of warnings
Signed-off-by: Tim Smith <tsmith@chef.io>
-rw-r--r-- | chef-config/lib/chef-config/path_helper.rb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/chef-config/lib/chef-config/path_helper.rb b/chef-config/lib/chef-config/path_helper.rb index e8a576c84f..c011c4f18a 100644 --- a/chef-config/lib/chef-config/path_helper.rb +++ b/chef-config/lib/chef-config/path_helper.rb @@ -235,7 +235,7 @@ module ChefConfig paths = paths.map { |home_path| home_path.gsub(path_separator, ::File::SEPARATOR) if home_path } # Filter out duplicate paths and paths that don't exist. - valid_paths = paths.select { |home_path| home_path && Dir.exists?(home_path.force_encoding("utf-8")) } + valid_paths = paths.select { |home_path| home_path && Dir.exist?(home_path.force_encoding("utf-8")) } valid_paths = valid_paths.uniq # Join all optional path elements at the end. |