Browse Source

ox-publish: Fix resolving url-encoded external links

* lisp/ox-publish.el (org-publish-resolve-external-link): Handle
  url-encoded links.  Do not ask to create a new headline if none is
  found.
Nicolas Goaziou 1 year ago
parent
commit
26c2ad99cf
1 changed files with 2 additions and 1 deletions
  1. 2 1
      lisp/ox-publish.el

+ 2 - 1
lisp/ox-publish.el

@@ -1150,7 +1150,8 @@ references with `org-export-get-reference'."
 	     (substring search 1)
 	   (with-current-buffer (find-file-noselect file)
 	     (org-with-point-at 1
-	       (org-link-search search nil t)
+	       (let ((org-link-search-must-match-exact-headline t))
+		 (org-link-search (org-link-unescape search) nil t))
 	       (and (org-at-heading-p)
 		    (org-string-nw-p (org-entry-get (point) "CUSTOM_ID"))))))))
    ((not org-publish-cache)