Browse Source

Prevent creation of duplicate footnote sections.

* lisp/org-footnote.el: (org-footnote-create-definition): Allow for
  footnote sections above the current footnote insertion point.

Fixes bug in which org-mode will create a new footnote section if the
current footnote section is not beneath the current insertion point.
Matt Lundin 14 years ago
parent
commit
2444744985
1 changed files with 1 additions and 0 deletions
  1. 1 0
      lisp/org-footnote.el

+ 1 - 0
lisp/org-footnote.el

@@ -291,6 +291,7 @@ or new, let the user edit the definition of the footnote."
 	  ;; No section, put footnote into the current outline node
 	  nil
 	;; Try to find or make the special node
+	(goto-char (point-min))
 	(setq re (concat "^\\*+[ \t]+" org-footnote-section "[ \t]*$"))
 	(unless (or (re-search-forward re nil t)
 		    (and (progn (widen) t)