Add extra check for TimeRange validity.

This commit is contained in:
Sergio Martínez Portela 2023-04-23 20:49:28 +02:00
parent 302689a622
commit 790ef57598
1 changed files with 2 additions and 0 deletions

View File

@ -1067,6 +1067,8 @@ def token_from_type(tok_type):
class TimeRange:
def __init__(self, start_time: OrgTime, end_time: OrgTime):
assert start_time is not None
assert end_time is not None
self.start_time = start_time
self.end_time = end_time