From f7e489178120813a4aff0eff0140661bf402cbae Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Hugo=20H=C3=B6rnquist?= Date: Mon, 17 Aug 2020 10:17:33 +0200 Subject: Work on paths? --- module/output/ical.scm | 20 +++++++++++--------- 1 file changed, 11 insertions(+), 9 deletions(-) (limited to 'module/output/ical.scm') diff --git a/module/output/ical.scm b/module/output/ical.scm index 203c6d0e..45918be0 100644 --- a/module/output/ical.scm +++ b/module/output/ical.scm @@ -170,7 +170,8 @@ (add-child! cal event) - (awhen (param (prop* event 'DTSTART) 'TZID) + (awhen (and (provided? 'zoneinfo) + (param (prop* event 'DTSTART) 'TZID)) ;; TODO this is broken (add-child! cal (zoneinfo->vtimezone (zoneinfo) it))) @@ -209,14 +210,15 @@ CALSCALE:GREGORIAN\r (print-header) - (let ((tz-names (get-tz-names events))) - (for-each component->ical-string - ;; TODO we realy should send the earliest event from each timezone here, - ;; instead of just the first. - (map (lambda (name) (zoneinfo->vtimezone - (zoneinfo) - name (car events))) - tz-names))) + (when (provided? 'zoneinfo) + (let ((tz-names (get-tz-names events))) + (for-each component->ical-string + ;; TODO we realy should send the earliest event from each timezone here, + ;; instead of just the first. + (map (lambda (name) (zoneinfo->vtimezone + (zoneinfo) + name (car events))) + tz-names)))) (for-each component->ical-string events) -- cgit v1.2.3