Passed
Push — develop ( 089cb5...597d05 )
by nguereza
05:42
created
src/Http/InputClean.php 1 patch
Spacing   +19 added lines, -19 removed lines patch added patch discarded remove patch
@@ -64,17 +64,17 @@  discard block
 block discarded – undo
64 64
         '\'', '"', '&', '$', '#',
65 65
         '{', '}', '[', ']', '=',
66 66
         ';', '?', '%20', '%22',
67
-        '%3c',      // <
68
-        '%253c',    // <
69
-        '%3e',      // >
70
-        '%0e',      // >
71
-        '%28',      // (
72
-        '%29',      // )
73
-        '%2528',    // (
74
-        '%26',      // &
75
-        '%24',      // $
76
-        '%3f',      // ?
77
-        '%3b',      // ;
67
+        '%3c', // <
68
+        '%253c', // <
69
+        '%3e', // >
70
+        '%0e', // >
71
+        '%28', // (
72
+        '%29', // )
73
+        '%2528', // (
74
+        '%26', // &
75
+        '%24', // $
76
+        '%3f', // ?
77
+        '%3b', // ;
78 78
         '%3d'       // =
79 79
     ];
80 80
 
@@ -148,7 +148,7 @@  discard block
 block discarded – undo
148 148
             return $str;
149 149
         }
150 150
 
151
-        if ($str === '' || $str === null || is_bool($str) || ! $str || is_numeric($str)) {
151
+        if ($str === '' || $str === null || is_bool($str) || !$str || is_numeric($str)) {
152 152
             return $str;
153 153
         }
154 154
 
@@ -481,7 +481,7 @@  discard block
 block discarded – undo
481 481
 
482 482
         $flag = ENT_COMPAT | ENT_HTML5;
483 483
 
484
-        if (! isset($entities)) {
484
+        if (!isset($entities)) {
485 485
             $entities = array_map(
486 486
                 'strtolower',
487 487
                 get_html_translation_table(HTML_ENTITIES, $flag, $charset)
@@ -557,7 +557,7 @@  discard block
 block discarded – undo
557 557
         static $naughtyTags = [
558 558
             'alert', 'area', 'prompt', 'confirm', 'applet', 'audio', 'basefont',
559 559
             'base', 'behavior', 'bgsound', 'blink', 'body', 'embed', 'expression',
560
-            'form', 'frameset', 'frame', 'head', 'html', 'ilayer','iframe', 'input',
560
+            'form', 'frameset', 'frame', 'head', 'html', 'ilayer', 'iframe', 'input',
561 561
             'button', 'select', 'isindex', 'layer', 'link', 'meta', 'keygen', 'object',
562 562
             'plaintext', 'style', 'script', 'textarea', 'title', 'math', 'video', 'svg',
563 563
             'xml', 'xss'
@@ -601,7 +601,7 @@  discard block
 block discarded – undo
601 601
                 );
602 602
                 $attribute = [];
603 603
                 if (
604
-                    ! preg_match(
604
+                    !preg_match(
605 605
                         $attributesPattern,
606 606
                         $matches['attributes'],
607 607
                         $attribute,
@@ -623,7 +623,7 @@  discard block
 block discarded – undo
623 623
                     $attributes[] = $attribute[0][0];
624 624
                 }
625 625
 
626
-                $matches['attributes']  = (string) substr(
626
+                $matches['attributes'] = (string) substr(
627 627
                     $matches['attributes'],
628 628
                     $attribute[0][1] + strlen($attribute[0][0])
629 629
                 );
@@ -774,9 +774,9 @@  discard block
 block discarded – undo
774 774
         */
775 775
 
776 776
         if ($urlEncode) {
777
-            $nonDisplayables[] = '/%0[0-8bcef]/i';  // URL encoded 00-08, 11, 12, 14, 15
778
-            $nonDisplayables[] = '/%1[0-9a-f]/i';   // URL encoded 16-31
779
-            $nonDisplayables[] = '/%7f/i';      // URL encoded 127
777
+            $nonDisplayables[] = '/%0[0-8bcef]/i'; // URL encoded 00-08, 11, 12, 14, 15
778
+            $nonDisplayables[] = '/%1[0-9a-f]/i'; // URL encoded 16-31
779
+            $nonDisplayables[] = '/%7f/i'; // URL encoded 127
780 780
         }
781 781
 
782 782
         $nonDisplayables[] = '/[\x00-\x08\x0B\x0C\x0E-\x1F\x7F]+/S'; // 00-08, 11, 12, 14-31, 127
Please login to merge, or discard this patch.