Parcourir la source

org-cycle-hide-drawers: Remove an unnecessary state check

* lisp/org.el (org-cycle-hide-drawers): Don't check whether STATE is
`contents' within the `when' body because the `when' condition will
not pass in this case.
Kyle Meyer il y a 7 ans
Parent
commit
8ed27480aa
1 fichiers modifiés avec 1 ajouts et 1 suppressions
  1. 1 1
      lisp/org.el

+ 1 - 1
lisp/org.el

@@ -7322,7 +7322,7 @@ specifying which drawers should not be hidden."
   (when (and (derived-mode-p 'org-mode)
 	     (not (memq state '(overview folded contents))))
     (save-excursion
-      (let* ((globalp (memq state '(contents all)))
+      (let* ((globalp (eq state 'all))
              (beg (if globalp (point-min) (point)))
              (end (if globalp (point-max)
 		    (if (eq state 'children)