Don't extend calendar events will null values

This commit is contained in:
Fabio Manganiello 2018-12-20 16:40:14 +01:00
parent 8d497b0be7
commit b3ffb29726

View file

@ -107,7 +107,8 @@ class CalendarPlugin(Plugin, CalendarInterface):
events = [] events = []
for calendar in self.calendars: for calendar in self.calendars:
events.extend(calendar.get_upcoming_events().output) cal_events = calendar.get_upcoming_events().output or []
events.extend(cal_events)
events = sorted(events, key=lambda event: events = sorted(events, key=lambda event:
dateutil.parser.parse( dateutil.parser.parse(