Fix nullable parameter in work-contract API (#4063)
This commit is contained in:
@@ -66,12 +66,12 @@ final class Month extends BaseMonth
|
||||
return new Day($day);
|
||||
}
|
||||
|
||||
public function getExpectedTime(\DateTimeInterface $until): int
|
||||
public function getExpectedTime(?\DateTimeInterface $until = null): int
|
||||
{
|
||||
$time = 0;
|
||||
|
||||
foreach ($this->getDays() as $day) {
|
||||
if ($until < $day->getDay()) {
|
||||
if ($until !== null && $until < $day->getDay()) {
|
||||
break;
|
||||
}
|
||||
if ($day->getWorkingTime() !== null) {
|
||||
|
||||
Reference in New Issue
Block a user