aboutsummaryrefslogtreecommitdiff
path: root/module/calp/server/routes.scm
diff options
context:
space:
mode:
authorHugo Hörnquist <hugo@lysator.liu.se>2022-06-12 21:09:35 +0200
committerHugo Hörnquist <hugo@lysator.liu.se>2022-06-13 04:11:35 +0200
commit73a4bfc3d8e9bb5365e33a11a6ad3b8340d5195b (patch)
treee52324edc63a240e5c0b88081c325f789168a4c5 /module/calp/server/routes.scm
parentDocument timespec and zic. (diff)
downloadcalp-73a4bfc3d8e9bb5365e33a11a6ad3b8340d5195b.tar.gz
calp-73a4bfc3d8e9bb5365e33a11a6ad3b8340d5195b.tar.xz
Remove custom let*.
While it was nice, the most important part was the multi-valued let from srfi-71 (which is implemented in srfi-71)). The minor pattern matching structures could often be replaced with car+cdr, or a propper match.
Diffstat (limited to 'module/calp/server/routes.scm')
-rw-r--r--module/calp/server/routes.scm8
1 files changed, 4 insertions, 4 deletions
diff --git a/module/calp/server/routes.scm b/module/calp/server/routes.scm
index 762681d9..3d90cc04 100644
--- a/module/calp/server/routes.scm
+++ b/module/calp/server/routes.scm
@@ -73,7 +73,7 @@
path-join)))
,(_ "Return up"))))
,@(map (lambda (k)
- (let* ((stat (lstat (path-append prefix dir k))))
+ (let ((stat (lstat (path-append prefix dir k))))
`(tr (td ,(case (stat:type stat)
[(directory) "📁"]
[(regular) "📰"]
@@ -108,7 +108,7 @@
(lambda (search-term)
(aif (hash-ref query-pages search-term)
it
- (let* ((q (prepare-query
+ (let ((q (prepare-query
(build-query-proc search-term)
(get-event-set global-event-object))))
(hash-set! query-pages search-term q)
@@ -150,7 +150,7 @@
;; TODO any exception in this causes the whole page to fail
;; It would be much better if most of the page could still make it.
(GET "/week/:start-date.html" (start-date html)
- (let* ((start-date (start-of-week (parse-iso-date start-date))))
+ (let ((start-date (start-of-week (parse-iso-date start-date))))
(return `((content-type ,(content-type html)))
(with-output-to-string
(lambda ()
@@ -166,7 +166,7 @@
)))))))
(GET "/month/:start-date.html" (start-date html)
- (let* ((start-date (start-of-month (parse-iso-date start-date))))
+ (let ((start-date (start-of-month (parse-iso-date start-date))))
(return `((content-type ,(content-type html)))
(with-output-to-string
(lambda ()