Fixing an exception in contains_time?.
parent
931a10cd17
commit
a60385ba51
|
@ -87,7 +87,7 @@ module GPX
|
||||||
|
|
||||||
# Returns true if the given time is within this Segment.
|
# Returns true if the given time is within this Segment.
|
||||||
def contains_time?(time)
|
def contains_time?(time)
|
||||||
(time >= @earliest_point.time and time <= @latest_point.time)
|
(time >= @earliest_point.time and time <= @latest_point.time) rescue false
|
||||||
end
|
end
|
||||||
|
|
||||||
# Finds the closest point in time to the passed-in time argument. Useful
|
# Finds the closest point in time to the passed-in time argument. Useful
|
||||||
|
|
Loading…
Reference in New Issue