Fix: (org-ql-find) Widen buffer

This fixes the case in which a user calls org-ql-find from a narrowed
buffer and chooses a result outside the restriction.  This is already
done in, e.g. org-ql-open-link; it's just an oversight here.
This commit is contained in:
Adam Porter 2024-01-03 18:26:03 -06:00
parent 24b799ab0b
commit 8e9a8fe090
3 changed files with 44 additions and 39 deletions

View file

@ -77,8 +77,8 @@ single predicate)."
:prompt prompt)))
(set-buffer (marker-buffer marker))
(pop-to-buffer (current-buffer) org-ql-find-display-buffer-action)
(goto-char marker)
(run-hook-with-args 'org-ql-find-goto-hook)))
(org-with-point-at marker
(run-hook-with-args 'org-ql-find-goto-hook))))
;;;###autoload
(defun org-ql-refile (marker)