ical: Can configure delayed departure
This commit is contained in:
parent
2fc0f44de9
commit
a5282f5179
@ -15,6 +15,8 @@ class IcalModule:
|
||||
def __init__(self, config):
|
||||
self.cals = config.cals
|
||||
|
||||
self.delayed_departure = 100
|
||||
|
||||
self._cached_file = ".ical-%s.cache"
|
||||
self.cache_time = 15
|
||||
|
||||
@ -162,7 +164,7 @@ class IcalModule:
|
||||
|
||||
def event_coming(self, config):
|
||||
now = datetime.now(tz=pytz.timezone('Europe/Paris'))
|
||||
coming = datetime.now(tz=pytz.timezone('Europe/Paris')) + timedelta(minutes=80)
|
||||
coming = datetime.now(tz=pytz.timezone('Europe/Paris')) + timedelta(minutes=self.delayed_departure)
|
||||
|
||||
for evt in self.get_events(config):
|
||||
# Looking only the first event
|
||||
|
Loading…
Reference in New Issue
Block a user