nckx pushed a commit to branch master
in repository maintenance.
commit ade94305e483bf1d1133670e9bc2a9ddb98e76b1
Author: Tobias Geerinckx-Rice <[email protected]>
AuthorDate: Sun Sep 25 02:00:02 2022 +0200
goggles: Set rel="nofollow" on links.
* hydra/goggles.scm (make-line-renderer): Add rel="nofollow" to A elements.
---
hydra/goggles.scm | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/hydra/goggles.scm b/hydra/goggles.scm
index 5133506..dcc63eb 100755
--- a/hydra/goggles.scm
+++ b/hydra/goggles.scm
@@ -5,6 +5,7 @@
;; Copyright © 2019, 2020, 2021 Ricardo Wurmus <[email protected]>
;; Copyright © 2020 Ludovic Courtès <[email protected]>
;; Copyright © 2020 Andreas Enge <[email protected]>
+;; Copyright © 2022 Tobias Geerinckx-Rice <[email protected]>
;; Released under the GNU GPLv3 or any later version.
(use-modules (web http)
@@ -335,7 +336,8 @@ representation highlighting certain parts."
(cond
((string-match "http.?://.+" chunk)
(cons* " "
- `(a (@ (href ,chunk)) ,chunk)
+ `(a (@ (rel "nofollow")
+ (href ,chunk)) ,chunk)
" "
acc))
(else