mirror of
https://github.com/GothenburgBitFactory/taskwarrior.git
synced 2025-06-26 10:54:26 +02:00
Bug #669
- A test for due date < wait date in command.cpp only sometimes added an extra context.footnote complaining about the condition and was removed.
This commit is contained in:
parent
feb19cafdd
commit
6b5253e6a0
1 changed files with 0 additions and 23 deletions
|
@ -1985,29 +1985,6 @@ int handleModify (std::string& outs)
|
||||||
context.task.get ("recur") == "")
|
context.task.get ("recur") == "")
|
||||||
throw std::string ("You cannot remove the recurrence from a recurring task.");
|
throw std::string ("You cannot remove the recurrence from a recurring task.");
|
||||||
|
|
||||||
// This looks unnecessarily complex, but isn't. "due" and "wait" are
|
|
||||||
// independent and may exist without the other, but if both exist then wait
|
|
||||||
// must be before due.
|
|
||||||
if ((task->has ("wait") &&
|
|
||||||
context.task.has ("due") &&
|
|
||||||
Date (context.task.get ("due")) < Date (task->get ("wait")))
|
|
||||||
||
|
|
||||||
(context.task.has ("wait") &&
|
|
||||||
!context.task.has ("due") &&
|
|
||||||
task->has ("due") &&
|
|
||||||
Date (task->get ("due")) < Date (context.task.get ("wait")))
|
|
||||||
||
|
|
||||||
(context.task.has ("wait") &&
|
|
||||||
context.task.has ("due") &&
|
|
||||||
Date (context.task.get ("due")) < Date (context.task.get ("wait")))
|
|
||||||
||
|
|
||||||
(task->has ("wait") &&
|
|
||||||
task->has ("due") &&
|
|
||||||
Date (task->get ("due")) < Date (task->get ("wait"))))
|
|
||||||
{
|
|
||||||
context.footnote ("Warning: the wait date falls after the due date.");
|
|
||||||
}
|
|
||||||
|
|
||||||
// Make all changes.
|
// Make all changes.
|
||||||
bool warned = false;
|
bool warned = false;
|
||||||
foreach (other, all)
|
foreach (other, all)
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue