diff options
author | Arun Isaac | 2022-07-13 17:56:12 +0530 |
---|---|---|
committer | Arun Isaac | 2022-07-19 17:37:06 +0530 |
commit | 4d8f1332d3566b1d2ef3d41fbfd0f0975b058393 (patch) | |
tree | 00c6afac069fd1726e6a3bb125a6b3082bb50198 | |
parent | 2501279bf00d15d556b4bceb6813f760f814045e (diff) | |
download | tissue-4d8f1332d3566b1d2ef3d41fbfd0f0975b058393.tar.gz tissue-4d8f1332d3566b1d2ef3d41fbfd0f0975b058393.tar.lz tissue-4d8f1332d3566b1d2ef3d41fbfd0f0975b058393.zip |
issue: Quote tags with spaces instead of hyphenating them.
* tissue/issue.scm (document->sxml): Quote tags with spaces instead of
hyphenating them.
-rw-r--r-- | tissue/issue.scm | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/tissue/issue.scm b/tissue/issue.scm index 23625fa..9e2ca9c 100644 --- a/tissue/issue.scm +++ b/tissue/issue.scm @@ -183,10 +183,11 @@ object representing a list of search results." `(a (@ (href ,(string-append "/search?query=" (uri-encode - ;; Hyphenate tag if it has - ;; spaces. Xapian accepts hyphenated - ;; strings as exact phrases. - (string-append "tag:" (sanitize-string tag))))) + ;; Quote tag if it has spaces. + (string-append "tag:" + (if (string-any #\space tag) + (string-append "\"" tag "\"") + tag))))) (class ,(string-append "tag" (string-append " tag-" (sanitize-string tag)) (if (not (null? (lset-intersection |