org--confirm-resource-safe: Fix prompt when prompting in non-file Org buffers
authorIhor Radchenko <yantar92@posteo.net>
Fri, 23 Feb 2024 09:56:58 +0000 (12:56 +0300)
committerEli Zaretskii <eliz@gnu.org>
Sun, 24 Mar 2024 12:41:26 +0000 (08:41 -0400)
* lisp/org/org.el (org--confirm-resource-safe): When called from
non-file buffer, do not put stray "f" in the prompt.

lisp/org/org.el

index 76559c91cd3ca093b20401fe5b09c63d4683c502..154388f79c6bba8e8bc76cf0bdf9a06a94bfb7b5 100644 (file)
@@ -4671,9 +4671,9 @@ returns non-nil if any of them match."
                      (propertize domain 'face '(:inherit org-link :weight normal))
                      ") as safe.\n ")
                   "")
-                (propertize "f" 'face 'success)
                 (if current-file
                     (concat
+                     (propertize "f" 'face 'success)
                      " to download this resource, and permanently mark all resources in "
                      (propertize current-file 'face 'underline)
                      " as safe.\n ")