aboutsummaryrefslogtreecommitdiff
path: root/themes/default/layouts/partials/feeds-generate.html
diff options
context:
space:
mode:
authortdro <tdro@noreply.example.com>2022-06-02 20:29:14 -0400
committertdro <tdro@noreply.example.com>2022-06-02 20:29:14 -0400
commit4e26be95074a0be4f9cd45a1f3fc9b6dfe0790bd (patch)
treef81827fda491f710550df0d5df988d69fc85a497 /themes/default/layouts/partials/feeds-generate.html
parentd0713b5c29257f689981364d6b4c5df9863dc96a (diff)
downloadcanory-4e26be95074a0be4f9cd45a1f3fc9b6dfe0790bd.tar.gz
canory-4e26be95074a0be4f9cd45a1f3fc9b6dfe0790bd.tar.bz2
canory-4e26be95074a0be4f9cd45a1f3fc9b6dfe0790bd.zip
themes/default/layouts: Use urls.Parse instead of regular expression
For domain/host lookup.
Diffstat (limited to 'themes/default/layouts/partials/feeds-generate.html')
-rw-r--r--themes/default/layouts/partials/feeds-generate.html2
1 files changed, 1 insertions, 1 deletions
diff --git a/themes/default/layouts/partials/feeds-generate.html b/themes/default/layouts/partials/feeds-generate.html
index ca88409..e32c250 100644
--- a/themes/default/layouts/partials/feeds-generate.html
+++ b/themes/default/layouts/partials/feeds-generate.html
@@ -92,7 +92,7 @@
"FeedSourceLink" ($sourceLink | plainify | htmlUnescape)
"FeedSourceTitle" ($sourceTitle | plainify | htmlUnescape)
"FeedTitle" ($title | plainify | htmlUnescape)
- "FeedSourceDomain" ($sourceLink | plainify | htmlUnescape | replaceRE "^https?://([^/]+).*" "$1")
+ "FeedSourceDomain" (($sourceLink | plainify | htmlUnescape | urls.Parse).Host)
)
}}