Completed
Push — master ( fa5c54...e47d70 )
by Davide
04:12
created
src/Validator.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -328,12 +328,12 @@
 block discarded – undo
328 328
         $century = $this->calculateCentury($year);
329 329
 
330 330
         // validate and calculate birth date
331
-        if (!checkdate($month, $day, $century . $year)) {
331
+        if (!checkdate($month, $day, $century.$year)) {
332 332
             throw new Exception('The codice fiscale to validate has an non existent birth date');
333 333
         }
334 334
 
335 335
         $this->birthDate = new DateTime();
336
-        $this->birthDate->setDate($century . $year, $month, $day)->setTime(0, 0, 0)->format('Y-m-d');
336
+        $this->birthDate->setDate($century.$year, $month, $day)->setTime(0, 0, 0)->format('Y-m-d');
337 337
     }
338 338
 
339 339
     /**
Please login to merge, or discard this patch.
src/Calculator.php 1 patch
Spacing   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -41,11 +41,11 @@  discard block
 block discarded – undo
41 41
      */
42 42
     public function calculate()
43 43
     {
44
-        $temporaryCodiceFiscale = $this->calculateSurname() . $this->calculateName() .
45
-                $this->calculateBirthDateAndGender() . $this->calculateBelfioreCode();
44
+        $temporaryCodiceFiscale = $this->calculateSurname().$this->calculateName().
45
+                $this->calculateBirthDateAndGender().$this->calculateBelfioreCode();
46 46
         $temporaryCodiceFiscale = $this->calculateOmocodia($temporaryCodiceFiscale);
47 47
 
48
-        return $temporaryCodiceFiscale . $this->calculateCheckDigit($temporaryCodiceFiscale);
48
+        return $temporaryCodiceFiscale.$this->calculateCheckDigit($temporaryCodiceFiscale);
49 49
     }
50 50
 
51 51
     /**
@@ -92,7 +92,7 @@  discard block
 block discarded – undo
92 92
         $name = $this->cleanString($this->subject->getName());
93 93
         $consonants = str_replace($this->vowels, '', strtoupper($name));
94 94
         if (strlen($consonants) > 3) {
95
-            $result = $consonants[0] . $consonants[2] . $consonants[3];
95
+            $result = $consonants[0].$consonants[2].$consonants[3];
96 96
         } elseif (strlen($consonants) == 3) {
97 97
             $result = $consonants;
98 98
         } else {
@@ -113,7 +113,7 @@  discard block
 block discarded – undo
113 113
     {
114 114
         $string = $this->cleanString($string);
115 115
         $vowels = str_replace(str_split($consonants), '', strtoupper($string));
116
-        $result = substr($consonants . $vowels . 'XXX', 0, 3);
116
+        $result = substr($consonants.$vowels.'XXX', 0, 3);
117 117
 
118 118
         return $result;
119 119
     }
@@ -132,7 +132,7 @@  discard block
 block discarded – undo
132 132
             $day += 40;
133 133
         }
134 134
 
135
-        return $year . $month . $day;
135
+        return $year.$month.$day;
136 136
     }
137 137
 
138 138
     /**
Please login to merge, or discard this patch.