summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--mumi/web/view/utils.scm8
1 files changed, 2 insertions, 6 deletions
diff --git a/mumi/web/view/utils.scm b/mumi/web/view/utils.scm
index 9e9e11f..782f737 100644
--- a/mumi/web/view/utils.scm
+++ b/mumi/web/view/utils.scm
@@ -78,17 +78,13 @@
((#:result res #:context context)
(receive (processed new-context)
(process line context)
- `(#:result ,(append (list processed '(br)) res)
+ `(#:result ,(cons* '(br) processed res)
#:context ,(if new-context
(cons new-context context)
context))))))
'(#:result () #:context ())
(string-split text #\newline))))
- ;; Drop the first line break, because it's for an eof
- ;; read.
- (match (reverse (cadr (find-tail (cut eq? #:result <>) res)))
- ((_ . rest) rest)
- (() '()))))
+ (reverse (and=> (memq #:result res) cadr))))
(define colors
(circular-list "#8dd3c7" "#bebada" "#fb8072"