浏览代码

Tiny fix to `org-set-effort'

* lisp/org.el (org-set-effort): Use `equal' instead of `string='.

Since (string= "nil" nil) is non-nil, a "nil" heading could be mistaken
for the current clocked task if `org-clock-current-task' is not bound,
or if there is no current clocked task.
Nicolas Goaziou 8 年之前
父节点
当前提交
ecffcbcf1c
共有 1 个文件被更改,包括 1 次插入1 次删除
  1. 1 1
      lisp/org.el

+ 1 - 1
lisp/org.el

@@ -15711,7 +15711,7 @@ When INCREMENT is non-nil, set the property to the next allowed value."
      '((effort . identity)
        (effort-minutes . org-duration-string-to-minutes))
      val)
-    (when (string= heading (org-bound-and-true-p org-clock-current-task))
+    (when (equal heading (org-bound-and-true-p org-clock-current-task))
       (setq org-clock-effort (get-text-property (point-at-bol) 'effort))
       (org-clock-update-mode-line))
     (message "%s is now %s" prop val)))