浏览代码

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.