Skip to content

Commit

Permalink
Merge pull request #206 from amatsuda/warnings
Browse files Browse the repository at this point in the history
⚠ shadowing outer local variable - args
  • Loading branch information
grosser authored May 30, 2017
2 parents d396783 + 9bc9922 commit b4ef3d6
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions lib/parallel.rb
Original file line number Diff line number Diff line change
Expand Up @@ -219,12 +219,12 @@ def each(array, options={}, &block)

def any?(*args, &block)
raise "You must provide a block when calling #any?" if block.nil?
!each(*args) { |*args| raise Parallel::Kill if block.call(*args) }
!each(*args) { |*a| raise Parallel::Kill if block.call(*a) }
end

def all?(*args, &block)
raise "You must provide a block when calling #all?" if block.nil?
!!each(*args) { |*args| raise Parallel::Kill unless block.call(*args) }
!!each(*args) { |*a| raise Parallel::Kill unless block.call(*a) }
end

def each_with_index(array, options={}, &block)
Expand Down

0 comments on commit b4ef3d6

Please sign in to comment.