Passed
Branch master (521290)
by Alexander
03:13
created
src/DateTimeImmutable.php 1 patch
Braces   +1 added lines, -2 removed lines patch added patch discarded remove patch
@@ -31,8 +31,7 @@
 block discarded – undo
31 31
     {
32 32
         try {
33 33
             $this->phpDateTime = new PhpDateTime($dateString);
34
-        }
35
-        catch (PhpException $exception) {
34
+        } catch (PhpException $exception) {
36 35
             // Suspect it is a unixtime that could not be parsed.
37 36
             $this->phpDateTime = new PhpDateTime();
38 37
             $this->phpDateTime->setTimestamp($dateString);
Please login to merge, or discard this patch.
src/MonthImmutable.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -48,7 +48,7 @@  discard block
 block discarded – undo
48 48
             }
49 49
 
50 50
         } catch (Exception $exception) {
51
-            throw new Exception('Cannot construct instance of'.__CLASS__.' with parameter "'.$monthString.'". Reason: ' . $exception->getMessage());
51
+            throw new Exception('Cannot construct instance of' . __CLASS__ . ' with parameter "' . $monthString . '". Reason: ' . $exception->getMessage());
52 52
         }
53 53
     }
54 54
 
@@ -172,7 +172,7 @@  discard block
 block discarded – undo
172 172
      */
173 173
     public function getBegin()
174 174
     {
175
-        $start = new DateTimeImmutable($this->getYearMonthString().'-01 00:00:00');
175
+        $start = new DateTimeImmutable($this->getYearMonthString() . '-01 00:00:00');
176 176
 
177 177
         return $start;
178 178
     }
@@ -196,7 +196,7 @@  discard block
 block discarded – undo
196 196
      */
197 197
     public function getFirstDay()
198 198
     {
199
-        $firstDayOfMonth = new DateTimeImmutable($this->getYearMonthString().'-01 00:00:00');
199
+        $firstDayOfMonth = new DateTimeImmutable($this->getYearMonthString() . '-01 00:00:00');
200 200
 
201 201
         return $firstDayOfMonth;
202 202
     }
@@ -258,7 +258,7 @@  discard block
 block discarded – undo
258 258
 
259 259
     private function buildYearMonthString($year, $month)
260 260
     {
261
-        $yearMonthString = $year.'-'.str_pad($month, 2, '0', STR_PAD_LEFT);
261
+        $yearMonthString = $year . '-' . str_pad($month, 2, '0', STR_PAD_LEFT);
262 262
 
263 263
         return $yearMonthString;
264 264
     }
Please login to merge, or discard this patch.