diff options
author | Tim Smith <tsmith84@gmail.com> | 2020-01-23 16:05:42 -0800 |
---|---|---|
committer | Tim Smith <tsmith84@gmail.com> | 2020-01-23 16:51:18 -0800 |
commit | 614743e0fb0c830f2419b0f445084d8f5c731296 (patch) | |
tree | 757c49c484535158ea84c57628e821d9d927d143 /lib | |
parent | ca5cf342b9d63118b9d2248d0fa516b87d9cb0a1 (diff) | |
download | chef-614743e0fb0c830f2419b0f445084d8f5c731296.tar.gz |
Use .load! in the Cookbook loader not .load_cookbooks
We added a deprecation warning to load_cookbooks and this is going to cause a ton of console spam for end users.
Signed-off-by: Tim Smith <tsmith@chef.io>
Diffstat (limited to 'lib')
5 files changed, 5 insertions, 5 deletions
diff --git a/lib/chef/chef_fs/file_system/chef_server/cookbook_artifacts_dir.rb b/lib/chef/chef_fs/file_system/chef_server/cookbook_artifacts_dir.rb index 974bbc91fd..96f281253f 100644 --- a/lib/chef/chef_fs/file_system/chef_server/cookbook_artifacts_dir.rb +++ b/lib/chef/chef_fs/file_system/chef_server/cookbook_artifacts_dir.rb @@ -66,7 +66,7 @@ class Chef # Instantiate a proxy loader using the temporary symlink proxy_loader = Chef::Cookbook::CookbookVersionLoader.new(proxy_cookbook_path, other.chefignore) - proxy_loader.load_cookbooks + proxy_loader.load! cookbook_to_upload = proxy_loader.cookbook_version cookbook_to_upload.identifier = identifier diff --git a/lib/chef/chef_fs/file_system/chef_server/versioned_cookbooks_dir.rb b/lib/chef/chef_fs/file_system/chef_server/versioned_cookbooks_dir.rb index 9a65f70f33..a5d76d10c7 100644 --- a/lib/chef/chef_fs/file_system/chef_server/versioned_cookbooks_dir.rb +++ b/lib/chef/chef_fs/file_system/chef_server/versioned_cookbooks_dir.rb @@ -72,7 +72,7 @@ class Chef # Instantiate a proxy loader using the temporary symlink proxy_loader = Chef::Cookbook::CookbookVersionLoader.new(proxy_cookbook_path, other.chefignore) - proxy_loader.load_cookbooks + proxy_loader.load! cookbook_to_upload = proxy_loader.cookbook_version cookbook_to_upload.freeze_version if options[:freeze] diff --git a/lib/chef/chef_fs/file_system/repository/chef_repository_file_system_cookbook_artifact_dir.rb b/lib/chef/chef_fs/file_system/repository/chef_repository_file_system_cookbook_artifact_dir.rb index a15b47ca73..5c893952ee 100644 --- a/lib/chef/chef_fs/file_system/repository/chef_repository_file_system_cookbook_artifact_dir.rb +++ b/lib/chef/chef_fs/file_system/repository/chef_repository_file_system_cookbook_artifact_dir.rb @@ -29,7 +29,7 @@ class Chef cookbook_name, _dash, identifier = name.rpartition("-") # KLUDGE: We shouldn't have to use instance_variable_set loader.instance_variable_set(:@cookbook_name, cookbook_name) - loader.load_cookbooks + loader.load! cookbook_version = loader.cookbook_version cookbook_version.identifier = identifier cookbook_version diff --git a/lib/chef/chef_fs/file_system/repository/chef_repository_file_system_cookbook_dir.rb b/lib/chef/chef_fs/file_system/repository/chef_repository_file_system_cookbook_dir.rb index 4f8368b025..3aba5ba51b 100644 --- a/lib/chef/chef_fs/file_system/repository/chef_repository_file_system_cookbook_dir.rb +++ b/lib/chef/chef_fs/file_system/repository/chef_repository_file_system_cookbook_dir.rb @@ -143,7 +143,7 @@ class Chef def cookbook_version loader = Chef::Cookbook::CookbookVersionLoader.new(file_path, chefignore) - loader.load_cookbooks + loader.load! loader.cookbook_version end end diff --git a/lib/chef/chef_fs/file_system/repository/chef_repository_file_system_versioned_cookbook_dir.rb b/lib/chef/chef_fs/file_system/repository/chef_repository_file_system_versioned_cookbook_dir.rb index 4d76be579a..976e0f38f3 100644 --- a/lib/chef/chef_fs/file_system/repository/chef_repository_file_system_versioned_cookbook_dir.rb +++ b/lib/chef/chef_fs/file_system/repository/chef_repository_file_system_versioned_cookbook_dir.rb @@ -33,7 +33,7 @@ class Chef # KLUDGE: We shouldn't have to use instance_variable_set loader.instance_variable_set(:@cookbook_name, canonical_name) - loader.load_cookbooks + loader.load! loader.cookbook_version end end |