瀏覽代碼

org-footnote: remove unnecessary checks in footnotes regexps

* lisp/org-footnote.el (org-footnote-goto-definition): now,
  determining if point is at a footnote reference is entirely
  determined by `org-footnote-at-reference-p'. No need to check if
  pattern isn't at beginning of the line elsewhere.
Nicolas Goaziou 14 年之前
父節點
當前提交
9c31654077
共有 1 個文件被更改,包括 1 次插入1 次删除
  1. 1 1
      lisp/org-footnote.el

+ 1 - 1
lisp/org-footnote.el

@@ -277,7 +277,7 @@ If no footnote is found, return nil."
     (if (not def)
 	(error "Cannot find definition of footnote %s" label)
       (goto-char (nth 1 def))
-      (looking-at (format "^\\[%s\\]\\|.\\[%s:" label label))
+      (looking-at (format "\\[%s\\]\\|\\[%s:" label label))
       (goto-char (match-end 0))
       (org-show-context 'link-search)
       (message "Edit definition and go back with `C-c &' or, if unique, with `C-c C-c'."))))