FIX: The CN of the organizer may not necessarily be set in calendar.ical

This commit is contained in:
Fabio Manganiello 2022-02-17 10:55:35 +01:00
parent 94bb3e0541
commit 71cb73cf63
Signed by: blacklight
GPG key ID: D90FBA7F76362774

View file

@ -59,7 +59,7 @@ class CalendarIcalPlugin(Plugin, CalendarInterface):
'htmlLink': str(event.get('url')) if event.get('url') else None, 'htmlLink': str(event.get('url')) if event.get('url') else None,
'organizer': { 'organizer': {
'email': str(event.get('organizer')).replace('MAILTO:', ''), 'email': str(event.get('organizer')).replace('MAILTO:', ''),
'displayName': event.get('organizer').params['cn'] 'displayName': event.get('organizer').params.get('cn')
} if event.get('organizer') else None, } if event.get('organizer') else None,
'created': cls._convert_timestamp(event, 'created'), 'created': cls._convert_timestamp(event, 'created'),