Skip to content

Commit

Permalink
Be consistent in return value.
Browse files Browse the repository at this point in the history
  • Loading branch information
mrubinsk committed Nov 8, 2016
1 parent 3fae251 commit 02cddb9
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion nag/lib/Task.php
Expand Up @@ -720,7 +720,10 @@ public function getNextDue()
if (!$this->recurs()) {
return new Horde_Date($this->due);
}
return $this->recurrence->nextActiveRecurrence($this->due);
if (!($nextActive = $this->recurrence->nextActiveRecurrence($this->due))) {
return null;
}
return $nextActive;
}

/**
Expand Down

0 comments on commit 02cddb9

Please sign in to comment.