From 326367a36eca9cbeb0b861fb26f9a39b8489913f Mon Sep 17 00:00:00 2001 From: Paul Beckingham Date: Mon, 13 Jul 2015 11:40:42 -0400 Subject: [PATCH] TW-1488: You have more urgent tasks - Thanks to Stefan Betz, Denis Kasak. --- AUTHORS | 1 + ChangeLog | 1 + src/recur.cpp | 6 ++++-- 3 files changed, 6 insertions(+), 2 deletions(-) diff --git a/AUTHORS b/AUTHORS index 6a69d82fe..ab8dbcd8f 100644 --- a/AUTHORS +++ b/AUTHORS @@ -255,3 +255,4 @@ suggestions: Denis Kasak David Brenner Audrey Easterday + Stefan Betz diff --git a/ChangeLog b/ChangeLog index 6c97d52ad..0ae3258ed 100644 --- a/ChangeLog +++ b/ChangeLog @@ -20,6 +20,7 @@ Babej). - TW-1480 Weird behaviour on redundant filter beginning with number (thanks to Tomas Babej). +- TW-1488 You have more urgent tasks (thanks to Stefan Betz, Denis Kasak). - TW-1527 Extra spaces added around slashes (thanks to Renato Alves). - TW-1529 Parser incorrectly inserting spaces into task description (thanks to David Brenner). diff --git a/src/recur.cpp b/src/recur.cpp index c123d8caf..d5d6682c5 100644 --- a/src/recur.cpp +++ b/src/recur.cpp @@ -422,11 +422,13 @@ bool nag (Task& task) std::string nagMessage = context.config.get ("nag"); if (nagMessage != "") { - // Scan all pending tasks. + // Scan all pending, non-recurring tasks. auto pending = context.tdb2.pending.get_tasks (); for (auto& t : pending) { - if (t.urgency () > task.urgency ()) + if ((t.getStatus () == Task::pending || + t.getStatus () == Task::waiting) && + t.urgency () > task.urgency ()) { context.footnote (nagMessage); return true;