소스 검색

org-element: Fix small bug when parsing visible headlines only

* contrib/lisp/org-element.el (org-element-parse-elements): Fix bug
  when restricting parsing to visible headlines only.
Nicolas Goaziou 13 년 전
부모
커밋
3638097e5a
1개의 변경된 파일2개의 추가작업 그리고 3개의 파일을 삭제
  1. 2 3
      contrib/lisp/org-element.el

+ 2 - 3
contrib/lisp/org-element.el

@@ -3084,9 +3084,8 @@ Elements are accumulated into ACC."
 	      granularity
 	      visible-only
 	      (reverse element)))
-	    ;; Case 4.  Else, just accumulate ELEMENT, unless
-	    ;; GRANULARITY is set to `headline'.
-	    ((not (eq granularity 'headline)) element))))
+	    ;; Case 4.  Else, just accumulate ELEMENT.
+	    (t element))))
        acc)
       (org-skip-whitespace))
     ;; Return result.