mirror of
https://github.com/GothenburgBitFactory/taskwarrior.git
synced 2025-06-26 10:54:26 +02:00
Dependency: Consistency
- Modified the ::getBlockingTasks and ::getBlockedTasks to match the code that performs the dependency scan. While this doesn't change functionality, it does align the logic.
This commit is contained in:
parent
7f3db8f201
commit
156357285c
1 changed files with 4 additions and 4 deletions
|
@ -44,8 +44,8 @@ void dependencyGetBlocked (const Task& task, std::vector <Task>& blocked)
|
|||
|
||||
auto all = context.tdb2.pending.get_tasks ();
|
||||
for (auto& it : all)
|
||||
if ((it.getStatus () == Task::pending ||
|
||||
it.getStatus () == Task::waiting) &&
|
||||
if (it.getStatus () != Task::completed &&
|
||||
it.getStatus () != Task::deleted &&
|
||||
it.has ("depends") &&
|
||||
it.get ("depends").find (uuid) != std::string::npos)
|
||||
blocked.push_back (it);
|
||||
|
@ -57,8 +57,8 @@ void dependencyGetBlocking (const Task& task, std::vector <Task>& blocking)
|
|||
std::string depends = task.get ("depends");
|
||||
if (depends != "")
|
||||
for (auto& it : context.tdb2.pending.get_tasks ())
|
||||
if ((it.getStatus () == Task::pending ||
|
||||
it.getStatus () == Task::waiting) &&
|
||||
if (it.getStatus () != Task::completed &&
|
||||
it.getStatus () != Task::deleted &&
|
||||
depends.find (it.get ("uuid")) != std::string::npos)
|
||||
blocking.push_back (it);
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue