Browse Source

org-exp: remove tasks before normalizing footnotes

* lisp/org-exp.el (org-export-preprocess-string): if the last subtree
  is a task, footnotes may be removed along with the subtree. This
  patch ensures footnotes are put at the end of the buffer after the
  subtree has been removed.
Nicolas Goaziou 13 năm trước cách đây
mục cha
commit
301b3450fe
1 tập tin đã thay đổi với 3 bổ sung3 xóa
  1. 3 3
      lisp/org-exp.el

+ 3 - 3
lisp/org-exp.el

@@ -1138,13 +1138,13 @@ on this string to produce the exported version."
 				     (plist-get parameters :exclude-tags))
       (run-hooks 'org-export-preprocess-after-tree-selection-hook)
 
+      ;; Get rid of tasks, depending on configuration
+      (org-export-remove-tasks (plist-get parameters :tasks))
+
       ;; Normalize footnotes
       (when (plist-get parameters :footnotes)
 	(org-footnote-normalize nil 'pre-process-p))
 
-      ;; Get rid of tasks, depending on configuration
-      (org-export-remove-tasks (plist-get parameters :tasks))
-
       ;; Export code blocks
       (org-export-blocks-preprocess)