Browse Source

org.el: Clarify argument in org-todo's call to org-map-entries

* lisp/org.el (org-todo): Use nil instead of
org-loop-over-headlines-in-active-region as the MATCH argument.

org-loop-over-headlines-in-active-region isn't related to the MATCH
argument; it's related to SCOPE and decides the value of the let-bound
cl variable that's passed as SCOPE.  Note, though, that
org-loop-over-headlines-in-active-region is let-bound to nil around
the org-map-entries call, so this didn't cause any issues.
Kyle Meyer 4 years ago
parent
commit
3ed035ce3b
1 changed files with 2 additions and 2 deletions
  1. 2 2
      lisp/org.el

+ 2 - 2
lisp/org.el

@@ -10066,8 +10066,8 @@ When called through ELisp, arg is also interpreted in the following way:
 	    org-loop-over-headlines-in-active-region)
 	(org-map-entries
 	 (lambda () (org-todo arg))
-	 org-loop-over-headlines-in-active-region
-	 cl (when (org-invisible-p) (org-end-of-subtree nil t))))
+	 nil cl
+	 (when (org-invisible-p) (org-end-of-subtree nil t))))
     (when (equal arg '(16)) (setq arg 'nextset))
     (when (equal arg -1) (org-cancel-repeater) (setq arg nil))
     (let ((org-blocker-hook org-blocker-hook)