Fix: (org-ql-view--contract-buffers-files) Only compare to function
If the org-agenda-files variable points to a file pointing to a list of agenda files, it shouldn't be compared to. We should only compare to the value returned by the org-agenda-files function. Fixes #104. Thanks to @gdindi for reporting.
This commit is contained in:
parent
81673fc7b5
commit
f4d7399e67
1 changed files with 8 additions and 8 deletions
|
|
@ -841,14 +841,14 @@ current buffer. Otherwise BUFFERS-FILES is returned unchanged."
|
||||||
list)))
|
list)))
|
||||||
;; TODO: Test this more exhaustively.
|
;; TODO: Test this more exhaustively.
|
||||||
(pcase buffers-files
|
(pcase buffers-files
|
||||||
((pred listp) (pcase (expand-files buffers-files)
|
((pred listp)
|
||||||
((or (pred (seq-set-equal-p (mapcar #'expand-file-name (org-agenda-files))))
|
(pcase (expand-files buffers-files)
|
||||||
(pred (seq-set-equal-p (mapcar #'expand-file-name org-agenda-files))))
|
((pred (seq-set-equal-p (mapcar #'expand-file-name (org-agenda-files))))
|
||||||
"org-agenda-files")
|
"org-agenda-files")
|
||||||
((pred (seq-set-equal-p (org-ql-search-directories-files)))
|
((pred (seq-set-equal-p (org-ql-search-directories-files)))
|
||||||
"org-directory")
|
"org-directory")
|
||||||
(_ (let ((print-length nil))
|
(_ (let ((print-length nil))
|
||||||
(concat "'" (prin1-to-string buffers-files))))))
|
(concat "'" (prin1-to-string buffers-files))))))
|
||||||
((pred (equal (current-buffer)))
|
((pred (equal (current-buffer)))
|
||||||
"buffer")
|
"buffer")
|
||||||
((or 'org-agenda-files '(function org-agenda-files))
|
((or 'org-agenda-files '(function org-agenda-files))
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue