summaryrefslogtreecommitdiff
path: root/lib/chef/cookbook_version.rb
diff options
context:
space:
mode:
authorLamont Granquist <lamont@scriptkiddie.org>2016-03-04 11:13:26 -0800
committerLamont Granquist <lamont@scriptkiddie.org>2016-03-04 11:13:26 -0800
commit6ec521c0b86c266b9dd5d17a6060139dab404c3b (patch)
treea27bf7a007bfeebd64258c2e5652f6da37b73efc /lib/chef/cookbook_version.rb
parentee53ee1aba16ee2ad7c1fdde18869af971dcba67 (diff)
parent4fd88f1f3c7d847712e61abab2bac6cb4a987265 (diff)
downloadchef-6ec521c0b86c266b9dd5d17a6060139dab404c3b.tar.gz
Merge pull request #4617 from chef/lcg/chefstyle-perf
Autofixing new Perf cops in 0.37.2
Diffstat (limited to 'lib/chef/cookbook_version.rb')
-rw-r--r--lib/chef/cookbook_version.rb4
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/chef/cookbook_version.rb b/lib/chef/cookbook_version.rb
index 2857d8098e..906b94baad 100644
--- a/lib/chef/cookbook_version.rb
+++ b/lib/chef/cookbook_version.rb
@@ -489,7 +489,7 @@ class Chef
# @deprecated This method was used by the Ruby Chef Server and is no longer
# needed. There is no replacement.
- def generate_manifest_with_urls(&url_generator)
+ def generate_manifest_with_urls
Chef.log_deprecation("Deprecated method #generate_manifest_with_urls.")
rendered_manifest = manifest.dup
@@ -497,7 +497,7 @@ class Chef
if rendered_manifest.has_key?(segment)
rendered_manifest[segment].each do |manifest_record|
url_options = { :cookbook_name => name.to_s, :cookbook_version => version, :checksum => manifest_record["checksum"] }
- manifest_record["url"] = url_generator.call(url_options)
+ manifest_record["url"] = yield(url_options)
end
end
end