[EMAIL PROTECTED] (Michael Herstine <[EMAIL PROTECTED]>) writes:

> Hello all,
>
> I've just started using Planner, and was horsing around with
> `planner-rank' this weekend.  I've stumbled across what looks like a
> bug (to me) in `planner-rank-update-current-task'.  Here's the
> offending line:
>
>   (when (and deadline
>              task-info
>              (not (equal status "X"))
>              (not (equal status "C")))
>       (setq urgency (planner-rank-calculate-urgency-from-deadline
>                    (planner-deadline-days-left deadline task-info)))
>       (planner-rank-change importance urgency))
>
> As I read this, the intent is to call
> `planner-rank-calculate-urgency-from-deadline' when the current task
> has a deadline and is neither completed or cancelled, and
> `planner-rank-change' otherwise.  However, the `when' clause will omit
> everthing after if it's condition isn't satisfied.  Should that not be
> an `if'?

No, I think the intent is to call planner-rank-change only when the
conditions in the when are met. We don't want to update the rank
information for tasks that are cancelled or done. And the urgency has to
be calculated before planner-rank-change is run.

-- 
John Sullivan
Emacs Planner Maintainer
http://www.wjsullivan.net/PlannerMode.html
GPG Key: AE8600B6

_______________________________________________
Planner-el-discuss mailing list
[email protected]
https://mail.gna.org/listinfo/planner-el-discuss

Reply via email to