Permalink
Browse files

Check whether acting on self in the common methods

  • Loading branch information...
1 parent f2dce10 commit 697221578055a1fa61fa33bf48fbce01eccee375 @ferrous26 committed Feb 12, 2012
Showing with 5 additions and 3 deletions.
  1. +0 −2 lib/rubygems-compile/commands/compile_command.rb
  2. +5 −1 lib/rubygems-compile/common_methods.rb
View
2 lib/rubygems-compile/commands/compile_command.rb
@@ -41,8 +41,6 @@ def usage # :nodoc:
def execute
gems = execution_list
- gems.delete_if { |spec| spec.name == 'rubygems-compile' }
-
if gems.count >= 10
alert 'This could take a while...'
end
View
6 lib/rubygems-compile/common_methods.rb
@@ -13,8 +13,12 @@ def execution_list
candidates << dependencies_for(*candidates) unless options[:ignore]
candidates
- end.flatten.uniq
end
+ gems.flatten!
+ gems.uniq!
+ gems.delete_if { |spec| spec.name == 'rubygems-compile' }
+ gems
+ end
def gems_list
# @todo Gem.source_index is going away...

0 comments on commit 6972215

Please sign in to comment.