guard against nil and false ranges
git-svn-id: file:///home/svn/framework3/trunk@13446 4d416f70-5f16-0410-b530-b9f4589650daunstable
parent
730e41263f
commit
f5862e87d0
|
@ -162,6 +162,9 @@ class RangeWalker
|
|||
# given RangeWalker
|
||||
#
|
||||
def include_range?(range_walker)
|
||||
return false if ((not @ranges) or @ranges.empty?)
|
||||
return false if not range_walker.ranges
|
||||
|
||||
range_walker.ranges.all? do |start, stop|
|
||||
ranges.any? do |self_start, self_stop|
|
||||
r = (self_start..self_stop)
|
||||
|
|
Loading…
Reference in New Issue