diff --git a/app/Models/Task.php b/app/Models/Task.php index d6b01e2a60..5c54c6ba42 100644 --- a/app/Models/Task.php +++ b/app/Models/Task.php @@ -149,7 +149,7 @@ class Task extends EntityModel $endTime = min($endTime, $endTimeCutoff); } - $duration += $endTime - $startTime; + $duration += max($endTime - $startTime, 0); } return $duration;