Handle rendering messages using the old reference schema in khoj.el

Previously references were a list instead of a map
This commit is contained in:
Debanjum Singh Solanky 2024-06-15 15:32:28 +05:30
parent db056c896d
commit c6b95f8776

View file

@ -921,7 +921,7 @@ RECEIVE-DATE is the message receive date."
(defun khoj--generate-reference (reference)
"Create `org-mode' footnotes with REFERENCE."
(setq khoj--reference-count (1+ khoj--reference-count))
(let ((compiled-reference (cdr (assoc 'compiled reference))))
(let ((compiled-reference (if (stringp reference) reference (cdr (assoc 'compiled reference)))))
(cons
(propertize (format "^{ [fn:%x]}" khoj--reference-count) 'help-echo compiled-reference)
(thread-last