Completed
Pull Request — master (#7)
by
unknown
01:58
created
src/Auth/AttributeMap.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -82,7 +82,7 @@
 block discarded – undo
82 82
 
83 83
                 switch ($value['type']) {
84 84
                     case 'array':
85
-                        $arr =  (array)$data[$value['attr']];
85
+                        $arr = (array)$data[$value['attr']];
86 86
                         unset($arr['count']);
87 87
                         $attrs[$attr] = $arr;
88 88
                     break;
Please login to merge, or discard this patch.
src/Http/Response.php 1 patch
Spacing   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -109,7 +109,7 @@  discard block
 block discarded – undo
109 109
      */
110 110
     public function removeHeader(string $header): Response
111 111
     {
112
-        if(isset($this->headers[$header])) {
112
+        if (isset($this->headers[$header])) {
113 113
             unset($this->headers[$header]);
114 114
         }
115 115
 
@@ -212,7 +212,7 @@  discard block
 block discarded – undo
212 212
             $this->terminate();
213 213
         }
214 214
         
215
-        if($this->body instanceof Closure) {
215
+        if ($this->body instanceof Closure) {
216 216
             $body = $this->body->call($this);
217 217
         } else {
218 218
             $body = $this->body;
@@ -368,14 +368,14 @@  discard block
 block discarded – undo
368 368
      * @param  string $format
369 369
      * @return Response
370 370
      */
371
-    public function setOutputFormat(?string $format=null): Response
371
+    public function setOutputFormat(?string $format = null) : Response
372 372
     {
373
-        if($format === null) {
373
+        if ($format === null) {
374 374
             $this->output_format = null;
375 375
             return $this->removeHeader('Content-Type');
376 376
         }
377 377
 
378
-        if(!array_key_exists($format, self::OUTPUT_FORMATS)) {
378
+        if (!array_key_exists($format, self::OUTPUT_FORMATS)) {
379 379
             throw new Exception('invalid output format given');
380 380
         }
381 381
 
Please login to merge, or discard this patch.
src/Http/Router/Route.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -118,12 +118,12 @@
 block discarded – undo
118 118
      * @param  ContainerInterface $container
119 119
      * @return array
120 120
      */
121
-    public function getCallable(?ContainerInterface $container=null): array
121
+    public function getCallable(?ContainerInterface $container = null) : array
122 122
     {
123 123
         if (is_object($this->class)) {
124 124
             $instance = $this->class;
125 125
         } else {
126
-            if($container === null) {
126
+            if ($container === null) {
127 127
                 $instance = new $this->class();
128 128
             } else {
129 129
                 $instance = $container->get($this->class);
Please login to merge, or discard this patch.
src/Http/Router.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -68,12 +68,12 @@  discard block
 block discarded – undo
68 68
      * @param   array $request
69 69
      * @return  void
70 70
      */
71
-    public function __construct(LoggerInterface $logger, ?array $request=null, ?ContainerInterface $container=null)
71
+    public function __construct(LoggerInterface $logger, ? array $request = null, ?ContainerInterface $container = null)
72 72
     {
73 73
         $this->logger = $logger;
74 74
         $this->container = $container;
75 75
 
76
-        if($request === null) {
76
+        if ($request === null) {
77 77
             $request = $_SERVER;
78 78
         }
79 79
 
@@ -286,7 +286,7 @@  discard block
 block discarded – undo
286 286
             'code'    => $exception->getCode()
287 287
         ];
288 288
 
289
-        if(defined("$class::HTTP_CODE")) {
289
+        if (defined("$class::HTTP_CODE")) {
290 290
             $http_code = $class::HTTP_CODE;
291 291
         } else {
292 292
             $http_code = 500;
Please login to merge, or discard this patch.
src/Config.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -42,9 +42,9 @@  discard block
 block discarded – undo
42 42
      * @param   string $config
43 43
      * @return  void
44 44
      */
45
-    public function __construct(?ConfigInterface $config=null)
45
+    public function __construct(?ConfigInterface $config = null)
46 46
     {
47
-        if($config !== null) {
47
+        if ($config !== null) {
48 48
             $this->_store = $config->map()->children();
49 49
         }
50 50
     }
@@ -69,8 +69,8 @@  discard block
 block discarded – undo
69 69
      */
70 70
     public function merge(Config $from): Config
71 71
     {
72
-        foreach($from as $key => $value) {
73
-            if(isset($this->_store[$key]) && $this->_store[$key] instanceof Config) {
72
+        foreach ($from as $key => $value) {
73
+            if (isset($this->_store[$key]) && $this->_store[$key] instanceof Config) {
74 74
                 $this->_store[$key]->merge($value);
75 75
             } else {
76 76
                 $this->_store[$key] = $value;
Please login to merge, or discard this patch.
src/Ldap.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -87,7 +87,7 @@
 block discarded – undo
87 87
      * @param   Logger $logger
88 88
      * @return  resource
89 89
      */
90
-    public function __construct(LoggerInterface $logger, ?Iterable $config=null)
90
+    public function __construct(LoggerInterface $logger, ?Iterable $config = null)
91 91
     {
92 92
         $this->setOptions($config);
93 93
         $this->logger = $logger;
Please login to merge, or discard this patch.
src/Log/Adapter/Syslog.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -45,7 +45,7 @@
 block discarded – undo
45 45
      *
46 46
      * @return  AdapterInterface
47 47
      */
48
-    public function setOptions(? Iterable $config = null): AdapterInterface
48
+    public function setOptions(? Iterable $config = null) : AdapterInterface
49 49
     {
50 50
         if ($config === null) {
51 51
             return $this;
Please login to merge, or discard this patch.
src/Config/Struct.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -66,8 +66,8 @@
 block discarded – undo
66 66
     protected function mapArray(array $array): Config
67 67
     {
68 68
         $config = new Config();
69
-        foreach($array as $key => $value) {
70
-            if(is_array($value)) {
69
+        foreach ($array as $key => $value) {
70
+            if (is_array($value)) {
71 71
                 $config[$key] = $this->mapArray($value);
72 72
             } else {
73 73
                 $config[$key] = $value;
Please login to merge, or discard this patch.
src/Config/Xml.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -119,7 +119,7 @@  discard block
 block discarded – undo
119 119
             if (count($simplexml_child->children()) === 0) {
120 120
                 if (!isset($simplexml_to->{$simplexml_child->getName()})) {
121 121
                     $simplexml_to->addChild($simplexml_child->getName(), htmlspecialchars((string)$simplexml_child));
122
-                } elseif(count($simplexml_to->{$simplexml_child->getName()}->children()) === 0) {
122
+                } elseif (count($simplexml_to->{$simplexml_child->getName()}->children()) === 0) {
123 123
                     $simplexml_to->{$simplexml_child->getName()} = htmlspecialchars((string)$simplexml_child);
124 124
                 }
125 125
             } else {
@@ -201,7 +201,7 @@  discard block
 block discarded – undo
201 201
      * @param   SimpleXMLElement $xml
202 202
      * @return  Config
203 203
      */
204
-    public function map(?SimpleXMLElement $xml = null): Config
204
+    public function map(?SimpleXMLElement $xml = null) : Config
205 205
     {
206 206
         if ($xml === null) {
207 207
             $xml = $this->store;
@@ -209,7 +209,7 @@  discard block
 block discarded – undo
209 209
 
210 210
         $config = new Config();
211 211
         foreach ($xml->getNamespaces() + [null] as $prefix => $namespace) {
212
-            if($prefix === self::CONFIG_FEATURE_NAMESPACE_PREFIX) {
212
+            if ($prefix === self::CONFIG_FEATURE_NAMESPACE_PREFIX) {
213 213
                 continue;
214 214
             }
215 215
 
@@ -227,7 +227,7 @@  discard block
 block discarded – undo
227 227
         }
228 228
 
229 229
         foreach ($xml as $name => $element) {
230
-            if(isset($element->attributes(self::CONFIG_FEATURE_NAMESPACE)->name)) {
230
+            if (isset($element->attributes(self::CONFIG_FEATURE_NAMESPACE)->name)) {
231 231
                 $name = (string)$element->attributes(self::CONFIG_FEATURE_NAMESPACE)->name;
232 232
             }
233 233
 
Please login to merge, or discard this patch.