diff options
author | Denys Nykula <vegan@libre.net.ua> | 2024-01-11 17:05:42 +0200 |
---|---|---|
committer | David Thompson <dthompson2@worcester.edu> | 2024-01-16 14:08:58 -0500 |
commit | 0abc3b9c0d931715a31ae19006a0fbbe97066dba (patch) | |
tree | 47753a4d6cd776a32eedf62e570781e9af6e2541 | |
parent | b3512e0372997bb3c117f1912ce18693b37ea502 (diff) |
builder: atom: Add scheme to self-link.
Planet Scheme uses the URL in the sidebar.
A href without a scheme is considered a relative path.
Probably that's why I get a 404 when I click Spritely Institute.
-rw-r--r-- | haunt/builder/atom.scm | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/haunt/builder/atom.scm b/haunt/builder/atom.scm index cc35b78..9a015b2 100644 --- a/haunt/builder/atom.scm +++ b/haunt/builder/atom.scm @@ -197,10 +197,12 @@ the blog's prefix and post prefix." (id ,uri) (subtitle ,subtitle) (updated ,(date->string* (current-date))) - (link (@ (href ,(string-append (site-domain site) - "/" file-name)) - (rel "self"))) - (link (@ (href ,(site-domain site)))) + (link (@ (href ,uri) (rel "self"))) + (link (@ (href + ,(uri->string + (build-uri + (site-scheme site) + #:host (site-domain site)))))) ,@(map (cut post->atom-entry site <> #:blog-prefix blog-prefix) (take-up-to max-entries (filter posts)))) |