summaryrefslogtreecommitdiff
path: root/ennu.el
diff options
context:
space:
mode:
authorArun Isaac2020-03-15 02:18:50 +0530
committerArun Isaac2020-03-15 02:35:11 +0530
commit24ecff59b699453ec5fd307e5249a590f7316989 (patch)
tree4d9bdb583606528304d5933fad36048f90646842 /ennu.el
parente83b52ef4e6ca122fb196bf666e08544ad945e01 (diff)
downloadennum-24ecff59b699453ec5fd307e5249a590f7316989.tar.gz
ennum-24ecff59b699453ec5fd307e5249a590f7316989.tar.lz
ennum-24ecff59b699453ec5fd307e5249a590f7316989.zip
Handle posts with no author metadata.
* ennu.el (ennu--read-post): Export author metadata only if it is non-nil.
Diffstat (limited to 'ennu.el')
-rw-r--r--ennu.el3
1 files changed, 2 insertions, 1 deletions
diff --git a/ennu.el b/ennu.el
index 4d5b0ff..adcae17 100644
--- a/ennu.el
+++ b/ennu.el
@@ -57,7 +57,8 @@
(ennu-make-post
:filename filename
:slug (file-name-base filename)
- :author (funcall export (first (plist-get metadata :author)))
+ :author (when-let (author (plist-get metadata :author))
+ (funcall export (first author)))
:date (org-timestamp-to-time (first (plist-get metadata :date)))
:language (plist-get metadata :language)
:links links