1
0
mirror of https://git.savannah.gnu.org/git/emacs/org-mode.git synced 2024-11-24 07:20:29 +00:00

org-attach: Bind org-attach-method for org-attach-url

* lisp/org-attach.el (org-attach-url): Let-bind org-attach-method to
`url` so that org-attach-attach calls the correct method.

Before 72124726a (org-attach: Make dispatcher commands customizable,
2019-04-26), the dispatcher masked this issue by let-binding
org-attach-method around its call to org-attach-url.

Reported-by: stardiviner <numbchild@gmail.com>
<https://lists.gnu.org/archive/html/emacs-orgmode/2019-06/msg00130.html>
This commit is contained in:
Kyle Meyer 2019-06-21 18:14:49 -04:00
parent 1b74ae0ba3
commit 8e7280896f

View File

@ -419,7 +419,8 @@ Only do this when `org-attach-store-link-p' is non-nil."
(defun org-attach-url (url)
(interactive "MURL of the file to attach: \n")
(org-attach-attach url))
(let ((org-attach-method 'url))
(org-attach-attach url)))
(defun org-attach-buffer (buffer-name)
"Attach BUFFER-NAME's contents to current task.