mirror of
https://github.com/GothenburgBitFactory/taskwarrior.git
synced 2025-08-25 03:07:20 +02:00
This reverts commit 6d3519419e
.
This commit is contained in:
parent
9db275fedb
commit
d4649dd210
2 changed files with 33 additions and 44 deletions
|
@ -135,10 +135,9 @@ void handleRecurrence ()
|
|||
|
||||
////////////////////////////////////////////////////////////////////////////////
|
||||
// Determine a start date (due), an optional end date (until), and an increment
|
||||
// period (recur). Then generate a set of corresponding dates. Only recurrences
|
||||
// in the future are returned; see #3501.
|
||||
// period (recur). Then generate a set of corresponding dates.
|
||||
//
|
||||
// Returns false if the parent recurring task is deleted.
|
||||
// Returns false if the parent recurring task is depleted.
|
||||
bool generateDueDates (Task& parent, std::vector <Datetime>& allDue)
|
||||
{
|
||||
// Determine due date, recur period and until date.
|
||||
|
@ -159,12 +158,9 @@ bool generateDueDates (Task& parent, std::vector <Datetime>& allDue)
|
|||
auto recurrence_limit = Context::getContext ().config.getInteger ("recurrence.limit");
|
||||
int recurrence_counter = 0;
|
||||
Datetime now;
|
||||
Datetime today = now.startOfDay();
|
||||
for (Datetime i = due; ; i = getNextRecurrence (i, recur))
|
||||
{
|
||||
// Do not add tasks before today (but allow today for the common `due:today` form).
|
||||
if (i >= today)
|
||||
allDue.push_back (i);
|
||||
allDue.push_back (i);
|
||||
|
||||
if (specificEnd && i > until)
|
||||
{
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue