branch: externals/org
commit 6daeb5da622a7a2a4ab81a145dfcb9f100132a89
Author: Ihor Radchenko <yanta...@posteo.net>
Commit: Ihor Radchenko <yanta...@posteo.net>

    org-olpath-completing-read: Fix completion boundaries
    
    * lisp/org-refile.el (org-olpath-completing-read): Start completion
    boundary from 0.  This should be done because completion table
    produced by `org-refile-get-targets' contains full OLP as
    parent/child/child/... and we are completing against it, not just
    against current siblings.
    
    Reported-by: Martin Marshall <l...@martinmarshall.com>
    Link: 
https://orgmode.org/list/caofdpfuz-5b3l5sadrdfyetswfc9hlqaxgwngnfem50jzow...@mail.gmail.com
---
 lisp/org-refile.el | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)

diff --git a/lisp/org-refile.el b/lisp/org-refile.el
index cdb0fc83c2..5e9cecd746 100644
--- a/lisp/org-refile.el
+++ b/lisp/org-refile.el
@@ -780,9 +780,7 @@ this function appends the default value from
                         (all-completions string thetable predicate))))
               ((eq (car-safe flag) 'boundaries)
                ;; See `completion-file-name-table'.
-               (let ((start (or (and (string-match "/" string)
-                                     (match-beginning 0))
-                                (length string)))
+               (let ((start 0)
                      (end (and (string-match "/" (cdr flag))
                                (match-beginning 0))))
                  `(boundaries ,start . ,end)))

Reply via email to