diff --git a/notes.org b/notes.org index 48f914a..223a652 100644 --- a/notes.org +++ b/notes.org @@ -4184,6 +4184,6 @@ I don't need this right now, but it might come in handy here or elsewhere. ** File-local variables # Local Variables: -# before-save-hook: (org-make-toc (lambda () (when (fboundp 'unpackaged/org-fix-blank-lines) (unpackaged/org-fix-blank-lines t))) (lambda () (when (fboundp 'ap/org-sort-entries-recursive-multi) (save-excursion (goto-char (point-min)) (ap/org-sort-entries-recursive-multi '(?a ?p ?o)))))) +# before-save-hook: ((lambda () (when (fboundp 'unpackaged/org-fix-blank-lines) (unpackaged/org-fix-blank-lines t))) (lambda () (when (fboundp 'ap/org-sort-entries-recursive-multi) (save-excursion (goto-char (point-min)) (ap/org-sort-entries-recursive-multi '(?a ?p ?o))))) org-make-toc) # End: diff --git a/org-ql-view.el b/org-ql-view.el index f5f7fb7..0101a69 100644 --- a/org-ql-view.el +++ b/org-ql-view.el @@ -662,9 +662,10 @@ When opened, the link searches the buffer it's opened from." ("containing file" nil) (buffers-files (prin1-to-string buffers-files)))) (string-or-file-buffer-p - (thing) (or (stringp thing) - (and (bufferp thing) - (buffer-file-name thing))))) + (thing) (cl-typecase thing + (string thing) + (buffer (or (buffer-file-name thing) + (buffer-file-name (buffer-base-buffer thing))))))) (unless (or (string-or-file-buffer-p org-ql-view-buffers-files) (and (listp org-ql-view-buffers-files) (cl-every #'string-or-file-buffer-p org-ql-view-buffers-files)))