summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--ennum.el18
1 files changed, 9 insertions, 9 deletions
diff --git a/ennum.el b/ennum.el
index bfd3bc7..a5a37ab 100644
--- a/ennum.el
+++ b/ennum.el
@@ -295,15 +295,15 @@ code, without surrounding template. See `org-export-as'.
When optional argument OUTPUT-HTML-FILE is nil, return exported
result as a string."
- (let ((output-file (ennum--org-output-filename (ennum-post-filename post))))
- (ennum-mkdir-p (file-name-directory output-file))
- (let ((system-time-locale (map-elt (ennum-setting :locale-alist)
- (ennum-post-language post) nil 'string=))
- (ext-plist (list :ennum-post post)))
- (ennum-with-file-contents interned-org-file
- (if output-html-file
- (org-export-to-file 'ennum-html output-file nil nil nil body-only ext-plist)
- (org-export-as 'ennum-html nil nil body-only ext-plist))))))
+ (let ((system-time-locale (map-elt (ennum-setting :locale-alist)
+ (ennum-post-language post) nil 'string=))
+ (ext-plist (list :ennum-post post)))
+ (ennum-with-file-contents interned-org-file
+ (cond
+ (output-html-file
+ (ennum-mkdir-p (file-name-directory output-html-file))
+ (org-export-to-file 'ennum-html output-html-file nil nil nil body-only ext-plist))
+ (t (org-export-as 'ennum-html nil nil body-only ext-plist))))))
(defun ennum-publish-post (post)
(let ((interned-org-file (ennum-intern (ennum-post-filename post))))