aboutsummaryrefslogtreecommitdiff
path: root/web/webserver.scm
diff options
context:
space:
mode:
authorFrederick Muriuki Muriithi2024-11-19 10:16:57 -0600
committerFrederick Muriuki Muriithi2024-11-19 10:16:57 -0600
commit61868ebf68181f456fa59be2c638f1d57a83ac9d (patch)
treedae96f204f7d15d82879601103a145aa3ab35b75 /web/webserver.scm
parent24135fc9bcb01c896849532419e23badd6790eef (diff)
downloadgn-guile-61868ebf68181f456fa59be2c638f1d57a83ac9d.tar.gz
Change headers' list into alist
Change the headers list into an alist to ensure the static files are actually sent back rather than failing with a status 500 error.
Diffstat (limited to 'web/webserver.scm')
-rw-r--r--web/webserver.scm12
1 files changed, 6 insertions, 6 deletions
diff --git a/web/webserver.scm b/web/webserver.scm
index 4969f23..d2a8c8d 100644
--- a/web/webserver.scm
+++ b/web/webserver.scm
@@ -87,9 +87,9 @@ otherwise search for set/group data"
(modified (and stat
(make-time time-utc 0
(stat:mtime stat)))))
- (list `((content-type ,(assoc-ref file-mime-types
- (file-extension file-name)))
- (last-modified ,(time-utc->date modified)))
+ (list `((content-type . ,(assoc-ref file-mime-types
+ (file-extension file-name)))
+ (last-modified . ,(time-utc->date modified)))
(call-with-input-file file-name
get-bytevector-all))))
@@ -100,9 +100,9 @@ otherwise search for set/group data"
(modified (and stat
(make-time time-utc 0
(stat:mtime stat)))))
- (list `((content-type ,(assoc-ref file-mime-types
- (file-extension path)))
- (last-modified ,(time-utc->date modified)))
+ (list `((content-type . ,(assoc-ref file-mime-types
+ (file-extension path)))
+ (last-modified . ,(time-utc->date modified)))
(call-with-input-file path
get-bytevector-all))))