Skip to content

Commit

Permalink
coding standard
Browse files Browse the repository at this point in the history
  • Loading branch information
JanGalek committed Apr 13, 2018
1 parent 7e1ad05 commit 8e72f6e
Showing 1 changed file with 9 additions and 9 deletions.
18 changes: 9 additions & 9 deletions src/Galek/Utils/Calendar/Calendar.php
Expand Up @@ -23,11 +23,11 @@ class Calendar extends DateTime
public $shippingtime = 1;

/**
* Use 24 hours type
* ['work start ([hour,minute])', 'work_end ([hour,minute])']
* @example [ ['8','0'], ['16','30'] ]
* @var array
*/
* Use 24 hours type
* ['work start ([hour,minute])', 'work_end ([hour,minute])']
* @example [ ['8','0'], ['16','30'] ]
* @var array
*/
private $working_time = [
['8', '0'],
['16', '0'],
Expand Down Expand Up @@ -424,7 +424,7 @@ public function werbDif(): string
if ($diff === 1) {
return $local['yesterday'];
} else {
return $local['before'] . ' ' . $diff . ' ' . $local[ 'twoDays' ];
return $local['before'] . ' ' . $diff . ' ' . $local['twoDays'];
}
}

Expand Down Expand Up @@ -496,13 +496,13 @@ public function getWorkDay($next = false, $date = false): Calendar
$date->modify('+1 days');
}

if ($date->isWeekend()) {
if ($date->isSunday()) {
if (Day::isWeekend($date)) {
if (Day::isSunday($date)) {
$date->modify('+1 days');
} else {
$date->modify('+2 days');
}
} elseif ($date->isHoliday()) {
} elseif ($this->getHolidays()->isHoliday($date)) {
$date->modify('+1 days');
}

Expand Down

0 comments on commit 8e72f6e

Please sign in to comment.