diff options
author | John Keiser <john@johnkeiser.com> | 2016-01-15 14:34:35 -0800 |
---|---|---|
committer | John Keiser <john@johnkeiser.com> | 2016-01-15 15:04:39 -0800 |
commit | f7d83a4d895d5775245e80f4ad857ea92cfc5e02 (patch) | |
tree | df9149da15bca278a1b7a511643a5c105c2d3285 | |
parent | 2b8fb7f0888574e27b27d7e05c38a59417fd3f4c (diff) | |
download | chef-f7d83a4d895d5775245e80f4ad857ea92cfc5e02.tar.gz |
Allow top level directories to be created in local modejk/policies-local-mode
-rw-r--r-- | lib/chef/chef_fs/chef_fs_data_store.rb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/chef/chef_fs/chef_fs_data_store.rb b/lib/chef/chef_fs/chef_fs_data_store.rb index 0d4caad743..6bb884c59a 100644 --- a/lib/chef/chef_fs/chef_fs_data_store.rb +++ b/lib/chef/chef_fs/chef_fs_data_store.rb @@ -761,7 +761,7 @@ class Chef result = Chef::ChefFS::FileSystem.resolve_path(chef_fs, path.join("/")) if result.exists? result - elsif create + elsif create || path.size == 1 get_dir(path[0..-2], create).create_child(result.name, nil) else raise ChefZero::DataStore::DataNotFoundError.new(path) |