From 8ba0fb9fcf0d4d4d3497cf524b4c21c6fd4a86e3 Mon Sep 17 00:00:00 2001 From: Baptiste Fontaine Date: Mon, 17 Aug 2015 17:08:23 +0200 Subject: unnecessary calls to .select simplified These are minor perf optimizations. Closes Homebrew/homebrew#43028. Signed-off-by: Baptiste Fontaine --- Library/Homebrew/test/test_patching.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'Library/Homebrew/test/test_patching.rb') diff --git a/Library/Homebrew/test/test_patching.rb b/Library/Homebrew/test/test_patching.rb index 85c131021..0b6e3d941 100644 --- a/Library/Homebrew/test/test_patching.rb +++ b/Library/Homebrew/test/test_patching.rb @@ -17,7 +17,7 @@ class PatchingTests < Homebrew::TestCase def teardown @_f.clear_cache - @_f.patchlist.select(&:external?).each(&:clear_cache) + @_f.patchlist.each { |p| p.clear_cache if p.external? } end def assert_patched(formula) -- cgit v1.2.3