aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorArun Isaac2020-03-15 02:20:16 +0530
committerArun Isaac2020-03-15 02:35:12 +0530
commit9d411d414a2ec6df21126931d3f516bc66b64b2a (patch)
tree358f9888a13ad45e863d24259aa8bd20b1bee848
parent24ecff59b699453ec5fd307e5249a590f7316989 (diff)
downloadennum-9d411d414a2ec6df21126931d3f516bc66b64b2a.tar.gz
ennum-9d411d414a2ec6df21126931d3f516bc66b64b2a.tar.lz
ennum-9d411d414a2ec6df21126931d3f516bc66b64b2a.zip
Handle posts without summary metadata.
* ennu.el (ennu--read-post): Export summary metadata only if it is non-nil.
-rw-r--r--ennu.el3
1 files changed, 2 insertions, 1 deletions
diff --git a/ennu.el b/ennu.el
index adcae17..93abe57 100644
--- a/ennu.el
+++ b/ennu.el
@@ -72,7 +72,8 @@
(pcase tangle-output-file
("no" nil)
(_ tangle-output-file))))))))
- :summary (funcall export (first (plist-get metadata :summary)))
+ :summary (when-let (summary (plist-get metadata :summary))
+ (funcall export (first summary)))
:tags (plist-get metadata :filetags)
:thumbnail (or (plist-get metadata :thumbnail)
(seq-some (lambda (link)