Completed
Push — master ( 2cbe85...fa0a4e )
by Yılmaz
05:30 queued 02:26
created
src/Fullname.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -26,11 +26,11 @@
 block discarded – undo
26 26
      */
27 27
     const TITLES = [
28 28
         'Mr.',
29
-        'Ms.',   // address for women regardless of their marital status
29
+        'Ms.', // address for women regardless of their marital status
30 30
         'Mrs.',
31 31
         'Miss',
32
-        'Mx.',   // a title that does not indicate gender
33
-        'Adv.',  // advocate
32
+        'Mx.', // a title that does not indicate gender
33
+        'Adv.', // advocate
34 34
         'Capt.', // captain
35 35
         'Dr.',
36 36
         'Prof.', // professor
Please login to merge, or discard this patch.
src/IpRange.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -84,8 +84,8 @@
 block discarded – undo
84 84
     public static function createFromCidrNotation($cidr)
85 85
     {
86 86
         list($subnet, $bits) = explode('/', $cidr);
87
-        $start               = long2ip((ip2long($subnet)) & ((-1 << (32 - (int)$bits))));
88
-        $end                 = long2ip((ip2long($subnet)) + pow(2, (32 - (int)$bits))-1);
87
+        $start               = long2ip((ip2long($subnet)) & ((-1 << (32 - (int) $bits))));
88
+        $end                 = long2ip((ip2long($subnet)) + pow(2, (32 - (int) $bits)) - 1);
89 89
 
90 90
         return new IpRange(new IpAddress($start), new IpAddress($end));
91 91
     }
Please login to merge, or discard this patch.
src/Color.php 2 patches
Doc Comments   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -131,7 +131,7 @@
 block discarded – undo
131 131
     /**
132 132
      * Returns distance between two colors.
133 133
      * 
134
-     * @param  array  $color1 RGB color
134
+     * @param  integer[]  $color1 RGB color
135 135
      * @param  array  $color2 RGB color
136 136
      *
137 137
      * @see https://stackoverflow.com/questions/4057475/rounding-colours
Please login to merge, or discard this patch.
Spacing   +8 added lines, -8 removed lines patch added patch discarded remove patch
@@ -46,7 +46,7 @@  discard block
 block discarded – undo
46 46
     {
47 47
         $hex = $this->normalize($hex);
48 48
 
49
-        if(!$this->isValidHex($hex)) {
49
+        if (!$this->isValidHex($hex)) {
50 50
             throw new \InvalidArgumentException(sprintf('Given hex value %s is invalid', $hex));
51 51
         }
52 52
 
@@ -71,7 +71,7 @@  discard block
 block discarded – undo
71 71
     public function toRGB()
72 72
     {
73 73
         list($r, $g, $b) = sscanf($this->color, "%02x%02x%02x");
74
-        return [ $r, $g, $b ];
74
+        return [$r, $g, $b];
75 75
     }
76 76
 
77 77
     /**
@@ -127,7 +127,7 @@  discard block
 block discarded – undo
127 127
      * 
128 128
      * @return self
129 129
      */
130
-    public static function fromRGB($r,$g,$b)
130
+    public static function fromRGB($r, $g, $b)
131 131
     {
132 132
         $hex = dechex($r).dechex($g).dechex($b);
133 133
 
@@ -157,9 +157,9 @@  discard block
 block discarded – undo
157 157
     private function distanceL2(array $color1, array $color2)
158 158
     {
159 159
         return sqrt(
160
-            pow($color1[0]-$color2[0], 2) +
161
-            pow($color1[1]-$color2[1], 2) +
162
-            pow($color1[2]-$color2[2], 2)
160
+            pow($color1[0] - $color2[0], 2) +
161
+            pow($color1[1] - $color2[1], 2) +
162
+            pow($color1[2] - $color2[2], 2)
163 163
         );
164 164
     }
165 165
 
@@ -211,11 +211,11 @@  discard block
 block discarded – undo
211 211
     private function normalize($hex)
212 212
     {
213 213
         // Get rid of first # sign if it exists
214
-        if($hex[0] === '#') {
214
+        if ($hex[0] === '#') {
215 215
             $hex = substr($hex, 1);
216 216
         }
217 217
 
218
-        if(strlen($hex) === 3) {
218
+        if (strlen($hex) === 3) {
219 219
             // Convert to 6 digit version
220 220
             $hex = $hex[0].$hex[0].$hex[1].$hex[1].$hex[2].$hex[2];
221 221
         }
Please login to merge, or discard this patch.