aboutsummaryrefslogtreecommitdiff
path: root/module/vcomponent/ical
diff options
context:
space:
mode:
authorHugo Hörnquist <hugo@lysator.liu.se>2020-11-05 23:45:48 +0100
committerHugo Hörnquist <hugo@lysator.liu.se>2020-11-05 23:45:48 +0100
commit0e429de91e57c2445df4fdf2227f65af3e396d9c (patch)
tree9151ec03d773a70944e363855c5b9c296e6fce17 /module/vcomponent/ical
parentFix tidsrapport --output flag. (diff)
parentAdd comment about freeform fields. (diff)
downloadcalp-0e429de91e57c2445df4fdf2227f65af3e396d9c.tar.gz
calp-0e429de91e57c2445df4fdf2227f65af3e396d9c.tar.xz
Merge branch 'front'
Diffstat (limited to 'module/vcomponent/ical')
-rw-r--r--module/vcomponent/ical/output.scm8
-rw-r--r--module/vcomponent/ical/parse.scm2
2 files changed, 7 insertions, 3 deletions
diff --git a/module/vcomponent/ical/output.scm b/module/vcomponent/ical/output.scm
index a0816679..bcc6bb1d 100644
--- a/module/vcomponent/ical/output.scm
+++ b/module/vcomponent/ical/output.scm
@@ -44,12 +44,16 @@
[(memv key '(FREEBUSY))
(get-writer 'PERIOD)]
+ [(memv key '(CATEGORIES RESOURCES))
+ (lambda (p v)
+ (string-join (map (lambda (v) ((get-writer 'TEXT) p v))
+ v)
+ ","))]
+
[(memv key '(CALSCALE METHOD PRODID COMMENT DESCRIPTION
LOCATION SUMMARY TZID TZNAME
CONTACT RELATED-TO UID
- CATEGORIES RESOURCES
-
VERSION))
(get-writer 'TEXT)]
diff --git a/module/vcomponent/ical/parse.scm b/module/vcomponent/ical/parse.scm
index 9c555bca..8499d289 100644
--- a/module/vcomponent/ical/parse.scm
+++ b/module/vcomponent/ical/parse.scm
@@ -135,7 +135,7 @@
(let ((v ((get-parser 'TEXT) params value)))
(unless (= 1 (length v))
(warning "List in non-list field: ~s" v))
- (car v)))]
+ (string-join v ",")))]
;; TEXT, but allow a list
[(memv key '(CATEGORIES RESOURCES))