Apply exclusions to open interval only within range within interval start and now

Signed-off-by: Thomas Lauf <thomas.lauf@tngtech.com>
This commit is contained in:
Thomas Lauf 2019-04-11 10:42:08 +02:00
parent daec6b1fae
commit a672fd0647

View file

@ -601,9 +601,12 @@ std::vector <Interval> getTracked (
if (latest.is_open ())
{
// Get the set of expanded exclusions that overlap the range defined by the
// timeline.
auto exclusions = getAllExclusions (rules, filter);
// Get the set of expanded exclusions that overlap the range defined by the open interval.
Interval exclusion_range {};
exclusion_range.start = latest.start;
exclusion_range.end = Datetime();
auto exclusions = getAllExclusions (rules, exclusion_range);
if (! exclusions.empty ())
{
intervals.pop_back ();