branch: externals/dict-tree commit 61f0ce69118dcc97e5d13b0bbb93c618a011c2eb Author: Toby Cubitt <toby-predict...@dr-qubit.org> Commit: tsc25 <toby-predict...@dr-qubit.org>
Bug-fix in dictree--query --- dict-tree.el | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/dict-tree.el b/dict-tree.el index 949b89d..cd889e4 100644 --- a/dict-tree.el +++ b/dict-tree.el @@ -2037,9 +2037,11 @@ Returns nil if the stack is empty." (t ;; if there was nothing useful in the cache, do query and time it (let (time) (setq time (float-time)) - (setq cmpl (dictree--do-query dic arg triefun stackfun - (dictree--wrap-rankfun rank-function) - maxnum reverse nil)) + (setq cmpl + (dictree--do-query + dic arg triefun stackfun + (when rank-function (dictree--wrap-rankfun rank-function)) + maxnum reverse nil)) (setq time (- (float-time) time)) ;; if we're above the dictionary's completion cache threshold, cache ;; the result