Completed
Push — master ( 8b5d96...f11879 )
by Iqbal
04:21
created
src/AbstractParameterBag.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -60,7 +60,7 @@
 block discarded – undo
60 60
      */
61 61
     public function add(array $parameters)
62 62
     {
63
-        foreach($parameters as $key => $value) {
63
+        foreach ($parameters as $key => $value) {
64 64
             if (method_exists($this, 'set')) {
65 65
                 $this->{'set'}($key, $value);
66 66
             }
Please login to merge, or discard this patch.
src/File/Exception/AccessDeniedException.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -47,6 +47,6 @@
 block discarded – undo
47 47
      */
48 48
     public static function failedWriteFileOnDirectory($directory)
49 49
     {
50
-        return new self (sprintf('Unable to write in the "%s" directory', $directory));
50
+        return new self(sprintf('Unable to write in the "%s" directory', $directory));
51 51
     }
52 52
 }
Please login to merge, or discard this patch.
src/Header/Accept/AbstractAcceptHeader.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -53,7 +53,7 @@  discard block
 block discarded – undo
53 53
     public function add(AcceptHeaderItem $item)
54 54
     {
55 55
         $matcher = $this->getFieldValueMatcher();
56
-        if (null !== $matcher && false === (bool)preg_match($matcher, $item->getValue())) {
56
+        if (null !== $matcher && false === (bool) preg_match($matcher, $item->getValue())) {
57 57
             throw new InvalidArgumentException(sprintf(
58 58
                 'Item value "%s" is not match for given rules of "%s" header.',
59 59
                 $item->getValue(),
@@ -89,7 +89,7 @@  discard block
 block discarded – undo
89 89
      */
90 90
     public static function fromString($headerLine)
91 91
     {
92
-        $headerLine = (string)$headerLine;
92
+        $headerLine = (string) $headerLine;
93 93
         $pos = strpos($headerLine, ':');
94 94
         $fieldName = substr($headerLine, 0, $pos);
95 95
         $header = new static();
@@ -136,7 +136,7 @@  discard block
 block discarded – undo
136 136
     private function sort()
137 137
     {
138 138
         if (false === $this->sorted) {
139
-            uasort($this->items, function (AcceptHeaderItem $x, AcceptHeaderItem $y) {
139
+            uasort($this->items, function(AcceptHeaderItem $x, AcceptHeaderItem $y) {
140 140
                 $xPriority = $x->getPriority();
141 141
                 $yPriority = $y->getPriority();
142 142
 
Please login to merge, or discard this patch.
src/Header/CookieHeader.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -173,7 +173,7 @@
 block discarded – undo
173 173
      */
174 174
     public function getFieldValue()
175 175
     {
176
-        return implode(';', array_map(function ($key, $value) {
176
+        return implode(';', array_map(function($key, $value) {
177 177
 
178 178
             return sprintf('%s=%s', $key, $value);
179 179
         }, array_keys($this->cookies), $this->cookies));
Please login to merge, or discard this patch.
src/Header/GenericHeader.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -102,7 +102,7 @@
 block discarded – undo
102 102
 
103 103
         $max = PHP_INT_MAX;
104 104
 
105
-        return $deltaSeconds > $max ? $max : (int)$deltaSeconds;
105
+        return $deltaSeconds > $max ? $max : (int) $deltaSeconds;
106 106
     }
107 107
 
108 108
     /**
Please login to merge, or discard this patch.
src/HeaderBag.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -209,8 +209,8 @@
 block discarded – undo
209 209
     {
210 210
         $this->sort();
211 211
 
212
-        return implode("\r\n", array_map(function (array $item) {
213
-            return implode("\r\n", array_map(function (HeaderInterface $header) {
212
+        return implode("\r\n", array_map(function(array $item) {
213
+            return implode("\r\n", array_map(function(HeaderInterface $header) {
214 214
                 return (string) $header;
215 215
             }, $item));
216 216
         }, $this->parameters));
Please login to merge, or discard this patch.
src/HttpStatus.php 1 patch
Spacing   +13 added lines, -13 removed lines patch added patch discarded remove patch
@@ -23,7 +23,7 @@  discard block
 block discarded – undo
23 23
      */
24 24
     const HTTP_CONTINUE = 100;
25 25
     const HTTP_SWITCHING_PROTOCOLS = 101;
26
-    const HTTP_PROCESSING = 102;            // RFC2518
26
+    const HTTP_PROCESSING = 102; // RFC2518
27 27
     const HTTP_OK = 200;
28 28
     const HTTP_CREATED = 201;
29 29
     const HTTP_ACCEPTED = 202;
@@ -63,24 +63,24 @@  discard block
 block discarded – undo
63 63
     const HTTP_EXPECTATION_FAILED = 417;
64 64
     const HTTP_I_AM_A_TEAPOT = 418;
65 65
     const HTTP_UNPROCESSABLE_ENTITY = 422;
66
-    const HTTP_LOCKED = 423;                                                      // RFC4918
67
-    const HTTP_FAILED_DEPENDENCY = 424;                                           // RFC4918
68
-    const HTTP_RESERVED_FOR_WEBDAV_ADVANCED_COLLECTIONS_EXPIRED_PROPOSAL = 425;   // RFC2817
69
-    const HTTP_UPGRADE_REQUIRED = 426;                                            // RFC2817
70
-    const HTTP_PRECONDITION_REQUIRED = 428;                                       // RFC6585
71
-    const HTTP_TOO_MANY_REQUESTS = 429;                                           // RFC6585
72
-    const HTTP_REQUEST_HEADER_FIELDS_TOO_LARGE = 431;                             // RFC6585
66
+    const HTTP_LOCKED = 423; // RFC4918
67
+    const HTTP_FAILED_DEPENDENCY = 424; // RFC4918
68
+    const HTTP_RESERVED_FOR_WEBDAV_ADVANCED_COLLECTIONS_EXPIRED_PROPOSAL = 425; // RFC2817
69
+    const HTTP_UPGRADE_REQUIRED = 426; // RFC2817
70
+    const HTTP_PRECONDITION_REQUIRED = 428; // RFC6585
71
+    const HTTP_TOO_MANY_REQUESTS = 429; // RFC6585
72
+    const HTTP_REQUEST_HEADER_FIELDS_TOO_LARGE = 431; // RFC6585
73 73
     const HTTP_INTERNAL_SERVER_ERROR = 500;
74 74
     const HTTP_NOT_IMPLEMENTED = 501;
75 75
     const HTTP_BAD_GATEWAY = 502;
76 76
     const HTTP_SERVICE_UNAVAILABLE = 503;
77 77
     const HTTP_GATEWAY_TIMEOUT = 504;
78 78
     const HTTP_VERSION_NOT_SUPPORTED = 505;
79
-    const HTTP_VARIANT_ALSO_NEGOTIATES_EXPERIMENTAL = 506;                        // RFC2295
80
-    const HTTP_INSUFFICIENT_STORAGE = 507;                                        // RFC4918
81
-    const HTTP_LOOP_DETECTED = 508;                                               // RFC5842
82
-    const HTTP_NOT_EXTENDED = 510;                                                // RFC2774
83
-    const HTTP_NETWORK_AUTHENTICATION_REQUIRED = 511;                             // RFC6585
79
+    const HTTP_VARIANT_ALSO_NEGOTIATES_EXPERIMENTAL = 506; // RFC2295
80
+    const HTTP_INSUFFICIENT_STORAGE = 507; // RFC4918
81
+    const HTTP_LOOP_DETECTED = 508; // RFC5842
82
+    const HTTP_NOT_EXTENDED = 510; // RFC2774
83
+    const HTTP_NETWORK_AUTHENTICATION_REQUIRED = 511; // RFC6585
84 84
 
85 85
     /**
86 86
      * @var array
Please login to merge, or discard this patch.
src/Response/JsonResponse.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -47,7 +47,7 @@
 block discarded – undo
47 47
     {
48 48
         try {
49 49
             $data = json_encode($data);
50
-        } catch(RuntimeException $exception) {
50
+        } catch (RuntimeException $exception) {
51 51
             throw new $exception;
52 52
         }
53 53
 
Please login to merge, or discard this patch.
src/ServerBag.php 1 patch
Braces   +1 added lines, -2 removed lines patch added patch discarded remove patch
@@ -27,8 +27,7 @@
 block discarded – undo
27 27
         foreach ($this->parameters as $key => $value) {
28 28
             if (0 === strpos($key, 'HTTP_')) {
29 29
                 $headers[substr($key, 5)] = $value;
30
-            }
31
-            elseif (0 === strpos($key, 'CONTENT_')) {
30
+            } elseif (0 === strpos($key, 'CONTENT_')) {
32 31
                 $headers[$key] = $value;
33 32
             }
34 33
         }
Please login to merge, or discard this patch.