From f69de1a3415b4b17af2434d41e4bd504fcb99a97 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Kirill=20M=C3=BCller?= Date: Tue, 28 Oct 2025 17:49:53 +0100 Subject: [PATCH] fix: `create_absolute_links()` ignores `` tags without `href` attribute --- R/build-llm.R | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/R/build-llm.R b/R/build-llm.R index a5f3172c8..053cbc0a8 100644 --- a/R/build-llm.R +++ b/R/build-llm.R @@ -181,7 +181,9 @@ create_absolute_links <- function(main_html, url = NULL) { xml2::xml_attr(a, "class") <- NULL href <- xml2::xml_attr(a, "href") - is_internal <- !startsWith(href, "https") & !startsWith(href, "#") + is_internal <- !is.na(href) & + !startsWith(href, "https") & + !startsWith(href, "#") if (!is.null(url)) { href[is_internal] <- xml2::url_absolute(href[is_internal], url) }