From 29223fb65a7c4b5451542b3ace03aed2a924e339 Mon Sep 17 00:00:00 2001 From: John Kitchin Date: Mon, 2 Jan 2023 11:00:11 -0500 Subject: [PATCH] fix but in pre/post note edits. discovered from issue #1052. --- org-ref-citation-links.el | 16 ++++++++++------ 1 file changed, 10 insertions(+), 6 deletions(-) diff --git a/org-ref-citation-links.el b/org-ref-citation-links.el index f6d3f97a..6f76bf8f 100644 --- a/org-ref-citation-links.el +++ b/org-ref-citation-links.el @@ -930,16 +930,20 @@ arg COMMON, edit the common prefixes instead." (setq prefix (concat (read-string "prenote: " (string-trim - (plist-get - (nth index (plist-get data :references)) - :prefix))) + (or + (plist-get + (nth index (plist-get data :references)) + :prefix) + ""))) " ") suffix (concat " " (read-string "postnote: " (string-trim - (plist-get - (nth index (plist-get data :references)) - :suffix)))) + (or + (plist-get + (nth index (plist-get data :references)) + :suffix) + "")))) delta (- (length (plist-get (nth index (plist-get data :references)) :prefix))