summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEric Schulte <schulte.eric@gmail.com>2010-04-14 09:12:23 -0600
committerEric Schulte <schulte.eric@gmail.com>2010-04-14 09:12:41 -0600
commita2769bef610bfd02b3acc1f3ad83f018615def0e (patch)
treebbc890d2cc656b78df73f9837f21e7feefbdb5ca
parent12e73e58af9881faf5aba52db68798c16cff22c0 (diff)
downloadorg-mode-a2769bef610bfd02b3acc1f3ad83f018615def0e.tar.gz
org-mime: bug fixes, thanks to Eric S Fraga and Andrew Hyatt for their debugging help
-rw-r--r--contrib/lisp/org-mime.el15
1 files changed, 9 insertions, 6 deletions
diff --git a/contrib/lisp/org-mime.el b/contrib/lisp/org-mime.el
index 7891c63..b4882b0 100644
--- a/contrib/lisp/org-mime.el
+++ b/contrib/lisp/org-mime.el
@@ -53,6 +53,8 @@
;; (local-set-key "\C-c\M-o" 'org-mime-org-buffer-htmlize)))
;;; Code:
+(require 'cl)
+
(defcustom org-mime-default-header
"#+OPTIONS: latex:t\n"
"Default header to control html export options, and ensure
@@ -199,12 +201,13 @@ TMP-FILE during export."
(if (string= fmt "org") (length org-mime-default-header) 0)))))
(defun org-mime-apply-html-hook (html)
- (when org-mime-html-hook
- (with-temp-buffer
- (insert html)
- (goto-char (point-min))
- (run-hooks 'org-mime-html-hook)
- (buffer-string))))
+ (if org-mime-html-hook
+ (with-temp-buffer
+ (insert html)
+ (goto-char (point-min))
+ (run-hooks 'org-mime-html-hook)
+ (buffer-string))
+ html))
(defun org-mime-org-buffer-htmlize ()
"Export the current org-mode buffer to HTML using