emacs-elpa-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[elpa] externals/org 6ac5e0adc8 1/2: Merge branch 'bugfix'


From: ELPA Syncer
Subject: [elpa] externals/org 6ac5e0adc8 1/2: Merge branch 'bugfix'
Date: Sun, 13 Feb 2022 16:57:47 -0500 (EST)

branch: externals/org
commit 6ac5e0adc8bba85078c9dfabf03e571d44d11367
Merge: 27215ac5b5 17e4fe9093
Author: Nicolas Goaziou <mail@nicolasgoaziou.fr>
Commit: Nicolas Goaziou <mail@nicolasgoaziou.fr>

    Merge branch 'bugfix'
---
 lisp/org-lint.el              | 8 ++++++--
 testing/lisp/test-org-lint.el | 3 +++
 2 files changed, 9 insertions(+), 2 deletions(-)

diff --git a/lisp/org-lint.el b/lisp/org-lint.el
index 10b9a35893..b21412be12 100644
--- a/lisp/org-lint.el
+++ b/lisp/org-lint.el
@@ -829,8 +829,12 @@ Use \"export %s\" instead"
     reports))
 
 (defun org-lint-undefined-footnote-reference (ast)
-  (let ((definitions (org-element-map ast 'footnote-definition
-                      (lambda (f) (org-element-property :label f)))))
+  (let ((definitions
+          (org-element-map ast '(footnote-definition footnote-reference)
+           (lambda (f)
+              (and (or (eq 'footnote-definition (org-element-type f))
+                       (eq 'inline (org-element-property :type f)))
+                   (org-element-property :label f))))))
     (org-element-map ast 'footnote-reference
       (lambda (f)
        (let ((label (org-element-property :label f)))
diff --git a/testing/lisp/test-org-lint.el b/testing/lisp/test-org-lint.el
index b92b2a24e8..02973acb8e 100644
--- a/testing/lisp/test-org-lint.el
+++ b/testing/lisp/test-org-lint.el
@@ -378,6 +378,9 @@ This is not a node property
   (should-not
    (org-test-with-temp-text "Text[fn:1:inline reference]"
      (org-lint '(undefined-footnote-reference))))
+  (should-not
+   (org-test-with-temp-text "Text[fn:1:inline reference] [fn:1]"
+     (org-lint '(undefined-footnote-reference))))
   (should-not
    (org-test-with-temp-text "Text[fn::anonymous reference]"
      (org-lint '(undefined-footnote-reference)))))



reply via email to

[Prev in Thread] Current Thread [Next in Thread]