library/calendar_sync.py aktualisiert

This commit is contained in:
2025-07-12 08:39:38 +00:00
parent 89809af85b
commit d2887ac053

View File

@ -53,10 +53,12 @@ def sync_ics_to_caldav(module):
existing_events = {}
for event in target_cal.events():
if not event or not event.data:
continue
try:
for calendar in vobject.readComponents(event.data):
for component in calendar.components():
if component.name == 'VEVENT':
if component.name == 'VEVENT' and hasattr(component, "uid"):
uid = str(component.uid)
existing_events[uid] = event
except Exception as e:
@ -110,4 +112,3 @@ def run_module():
if __name__ == '__main__':
run_module()