From: plugd Date: Mon, 23 Aug 2021 09:41:07 +0000 (+0200) Subject: Display both URL and IRI for page info when they differ. X-Git-Tag: v3.3.0~8 X-Git-Url: https://thelambdalab.xyz/gitweb/index.cgi?a=commitdiff_plain;h=0d65ffa3ab238529a11d5c1a5d2dea5a6c27e9b4;p=elpher.git Display both URL and IRI for page info when they differ. --- diff --git a/elpher.el b/elpher.el index c57df7d..7df595d 100644 --- a/elpher.el +++ b/elpher.el @@ -2281,8 +2281,12 @@ When run interactively HOST-OR-URL is read from the minibuffer." (defun elpher-info-page (page) "Display URL of PAGE in minibuffer." - (let ((address (elpher-page-address page))) - (message "%s" (elpher-address-to-iri address)))) + (let* ((address (elpher-page-address page)) + (url (elpher-address-to-url address)) + (iri (elpher-address-to-iri address))) + (if (equal url iri) + (message "%s" url) + (message "%s (Raw: %s)" iri url)))) (defun elpher-info-link () "Display information on page corresponding to link at point."