Completed
Pull Request — master (#27)
by Sarel
01:13
created
src/HolidayIterator.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -37,7 +37,7 @@
 block discarded – undo
37 37
 {
38 38
     public function append($value)
39 39
     {
40
-        if (! $value instanceof HolidayIteratorItemInterface) {
40
+        if (!$value instanceof HolidayIteratorItemInterface) {
41 41
             return;
42 42
         }
43 43
 
Please login to merge, or discard this patch.
src/IteratorItem/EasterOrthodox.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -62,7 +62,7 @@
 block discarded – undo
62 62
         $orthodoxEaster = $this->getOrthodoxEaster($year);
63 63
         if ($endOfPessach > $orthodoxEaster) {
64 64
             $weekday = $endOfPessach->format('w');
65
-            return $endOfPessach->add(new \DateInterval('P' . (7-$weekday) . 'D'));
65
+            return $endOfPessach->add(new \DateInterval('P' . (7 - $weekday) . 'D'));
66 66
         }
67 67
 
68 68
         return $orthodoxEaster;
Please login to merge, or discard this patch.
src/CalendarDayFactory.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -36,7 +36,7 @@
 block discarded – undo
36 36
 {
37 37
     public static function createCalendarDay(int $day, int $month, string $calendar) : CalendarDay
38 38
     {
39
-        if (! Calendar::isValidCalendarName($calendar)) {
39
+        if (!Calendar::isValidCalendarName($calendar)) {
40 40
             throw new UnknownCalendar(sprintf(
41 41
                 'The calendar %s is not known to the ICU',
42 42
                 $calendar
Please login to merge, or discard this patch.
src/HolidayIteratorFactory.php 1 patch
Spacing   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -55,11 +55,11 @@  discard block
 block discarded – undo
55 55
         $dom->load($file);
56 56
         $dom->xinclude();
57 57
 
58
-        if (! $dom->schemaValidate(__DIR__ . '/../share/holidays.xsd')) {
58
+        if (!$dom->schemaValidate(__DIR__ . '/../share/holidays.xsd')) {
59 59
             throw new \Exception('XML-File does not validate agains schema');
60 60
         }
61 61
         foreach ($dom->documentElement->childNodes as $child) {
62
-            if (! $child instanceof \DOMElement) {
62
+            if (!$child instanceof \DOMElement) {
63 63
                 continue;
64 64
             }
65 65
             $iterator->append($this->getElement($child));
@@ -80,7 +80,7 @@  discard block
 block discarded – undo
80 80
         $file = __DIR__ . '/../share/%s.xml';
81 81
         $file1 = sprintf($file, $isoCode);
82 82
 
83
-        if (! is_readable($file1)) {
83
+        if (!is_readable($file1)) {
84 84
             throw new \UnexpectedValueException(sprintf(
85 85
                 'There is no holiday-file for %s',
86 86
                 $isoCode
@@ -110,7 +110,7 @@  discard block
 block discarded – undo
110 110
                 $day = CalendarDayFactory::createCalendarDay(
111 111
                     $child->getAttribute('day'),
112 112
                     $child->getAttribute('month'),
113
-                    ($child->hasAttribute('calendar')?$child->getAttribute('calendar'): 'gregorian')
113
+                    ($child->hasAttribute('calendar') ? $child->getAttribute('calendar') : 'gregorian')
114 114
                 );
115 115
                 if ($child->hasAttribute('year')) {
116 116
                     $day->setYear($child->getAttribute('year'));
@@ -124,7 +124,7 @@  discard block
 block discarded – undo
124 124
                 $day = CalendarDayFactory::createCalendarDay(
125 125
                     $child->getAttribute('day'),
126 126
                     $child->getAttribute('month'),
127
-                    ($child->hasAttribute('calendar')?$child->getAttribute('calendar'): 'gregorian')
127
+                    ($child->hasAttribute('calendar') ? $child->getAttribute('calendar') : 'gregorian')
128 128
                 );
129 129
 
130 130
                 return new DateFollowUp(
Please login to merge, or discard this patch.
src/CalendarDay.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -64,7 +64,7 @@  discard block
 block discarded – undo
64 64
 
65 65
     public function isSameDay(DateTimeInterface $dateTime) : bool
66 66
     {
67
-        $cal         = clone $this->calendar;
67
+        $cal = clone $this->calendar;
68 68
         $cal->setTime($dateTime->getTimestamp() * 1000);
69 69
 
70 70
         if (null !== $this->year &&
@@ -91,7 +91,7 @@  discard block
 block discarded – undo
91 91
         $day = $cal->toDateTime();
92 92
         $day->modify('next ' . $followUpDay);
93 93
         $cal->setTime($day->getTimestamp() * 1000);
94
-        $cal2         = clone $this->calendar;
94
+        $cal2 = clone $this->calendar;
95 95
         $cal2->setTime($dateTime->getTimestamp() * 1000);
96 96
 
97 97
         if (null !== $this->year && $cal->get(IntlCalendar::FIELD_YEAR) !== $cal2->get(IntlCalendar::FIELD_YEAR)) {
Please login to merge, or discard this patch.