Skip to content

Commit

Permalink
fix(ZMS-3466): improve validation prevent divide by zero
Browse files Browse the repository at this point in the history
  • Loading branch information
Tom Fink authored and Tom Fink committed Dec 9, 2024
1 parent 2a3cbb7 commit 4cbe423
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions zmsentities/src/Zmsentities/Availability.php
Original file line number Diff line number Diff line change
Expand Up @@ -555,6 +555,7 @@ public function validateSlotTime(\DateTimeInterface $startDate, \DateTimeInterfa
$slotTime = $this['slotTimeInMinutes'];
$startTimestamp = $startDate->getTimestamp();
$endTimestamp = $endDate->getTimestamp();

if ($slotTime === 0) {
$errorList[] = [
'type' => 'slotTime',
Expand Down

0 comments on commit 4cbe423

Please sign in to comment.