Add subtract_start to timerange object

This commit is contained in:
Matthias 2019-10-20 11:29:25 +02:00
parent 141c454187
commit 616fe08bce
1 changed files with 4 additions and 0 deletions

View File

@ -27,6 +27,10 @@ class TimeRange:
return (self.starttype == other.starttype and self.stoptype == other.stoptype
and self.startts == other.startts and self.stopts == other.stopts)
def subtract_start(self, seconds) -> None:
if self.startts:
self.startts = self.startts - seconds
@staticmethod
def parse_timerange(text: Optional[str]):
"""