Completed
Push — master ( 8cd077 )
by Tomáš
09:25
created
src/Standards/Squiz/Sniffs/Commenting/BlockCommentSniff.php 1 patch
Indentation   +20 added lines, -20 removed lines patch added patch discarded remove patch
@@ -41,7 +41,7 @@  discard block
 block discarded – undo
41 41
         return array(
42 42
                 T_COMMENT,
43 43
                 T_DOC_COMMENT_OPEN_TAG,
44
-               );
44
+                );
45 45
 
46 46
     }//end register()
47 47
 
@@ -69,19 +69,19 @@  discard block
 block discarded – undo
69 69
         if ($tokens[$stackPtr]['code'] === T_DOC_COMMENT_OPEN_TAG) {
70 70
             $nextToken = $phpcsFile->findNext(PHP_CodeSniffer_Tokens::$emptyTokens, ($stackPtr + 1), null, true);
71 71
             $ignore    = array(
72
-                          T_CLASS     => true,
73
-                          T_INTERFACE => true,
74
-                          T_TRAIT     => true,
75
-                          T_FUNCTION  => true,
76
-                          T_PUBLIC    => true,
77
-                          T_PRIVATE   => true,
78
-                          T_FINAL     => true,
79
-                          T_PROTECTED => true,
80
-                          T_STATIC    => true,
81
-                          T_ABSTRACT  => true,
82
-                          T_CONST     => true,
83
-                          T_VAR       => true,
84
-                         );
72
+                            T_CLASS     => true,
73
+                            T_INTERFACE => true,
74
+                            T_TRAIT     => true,
75
+                            T_FUNCTION  => true,
76
+                            T_PUBLIC    => true,
77
+                            T_PRIVATE   => true,
78
+                            T_FINAL     => true,
79
+                            T_PROTECTED => true,
80
+                            T_STATIC    => true,
81
+                            T_ABSTRACT  => true,
82
+                            T_CONST     => true,
83
+                            T_VAR       => true,
84
+                            );
85 85
             if (isset($ignore[$tokens[$nextToken]['code']]) === true) {
86 86
                 return;
87 87
             }
@@ -202,8 +202,8 @@  discard block
 block discarded – undo
202 202
                 }
203 203
 
204 204
                 $data = array(
205
-                         $expected,
206
-                         $leadingSpace,
205
+                            $expected,
206
+                            $leadingSpace,
207 207
                         );
208 208
 
209 209
                 $error = 'First line of comment not aligned correctly; expected %s but found %s';
@@ -245,8 +245,8 @@  discard block
 block discarded – undo
245 245
                 }
246 246
 
247 247
                 $data = array(
248
-                         $expected,
249
-                         $leadingSpace,
248
+                            $expected,
249
+                            $leadingSpace,
250 250
                         );
251 251
 
252 252
                 $error = 'Comment line indented incorrectly; expected at least %s but found %s';
@@ -277,8 +277,8 @@  discard block
 block discarded – undo
277 277
                 }
278 278
 
279 279
                 $data = array(
280
-                         $expected,
281
-                         $leadingSpace,
280
+                            $expected,
281
+                            $leadingSpace,
282 282
                         );
283 283
 
284 284
                 $error = 'Last line of comment aligned incorrectly; expected %s but found %s';
Please login to merge, or discard this patch.
src/Standards/Squiz/Sniffs/Commenting/LongConditionClosingCommentSniff.php 1 patch
Indentation   +7 added lines, -7 removed lines patch added patch discarded remove patch
@@ -34,9 +34,9 @@  discard block
 block discarded – undo
34 34
      * @var array
35 35
      */
36 36
     public $supportedTokenizers = array(
37
-                                   'PHP',
38
-                                   'JS',
39
-                                  );
37
+                                    'PHP',
38
+                                    'JS',
39
+                                    );
40 40
 
41 41
     /**
42 42
      * The openers that we are interested in.
@@ -51,7 +51,7 @@  discard block
 block discarded – undo
51 51
                                 T_WHILE,
52 52
                                 T_TRY,
53 53
                                 T_CASE,
54
-                               );
54
+                                );
55 55
 
56 56
     /**
57 57
      * The length that a code block must be before
@@ -190,9 +190,9 @@  discard block
 block discarded – undo
190 190
             $found = trim($tokens[$comment]['content']);
191 191
             $error = 'Incorrect closing comment; expected "%s" but found "%s"';
192 192
             $data  = array(
193
-                      $expected,
194
-                      $found,
195
-                     );
193
+                        $expected,
194
+                        $found,
195
+                        );
196 196
 
197 197
             $fix = $phpcsFile->addFixableError($error, $stackPtr, 'Invalid', $data);
198 198
             if ($fix === true) {
Please login to merge, or discard this patch.
src/Standards/Squiz/Sniffs/Commenting/PostStatementCommentSniff.php 1 patch
Indentation   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -34,9 +34,9 @@
 block discarded – undo
34 34
      * @var array
35 35
      */
36 36
     public $supportedTokenizers = array(
37
-                                   'PHP',
38
-                                   'JS',
39
-                                  );
37
+                                    'PHP',
38
+                                    'JS',
39
+                                    );
40 40
 
41 41
 
42 42
     /**
Please login to merge, or discard this patch.
src/Standards/Squiz/Sniffs/Functions/LowercaseFunctionKeywordsSniff.php 1 patch
Indentation   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -44,7 +44,7 @@  discard block
 block discarded – undo
44 44
                 T_PRIVATE,
45 45
                 T_PROTECTED,
46 46
                 T_STATIC,
47
-               );
47
+                );
48 48
 
49 49
     }//end register()
50 50
 
@@ -66,10 +66,10 @@  discard block
 block discarded – undo
66 66
         if ($content !== strtolower($content)) {
67 67
             $error = '%s keyword must be lowercase; expected "%s" but found "%s"';
68 68
             $data  = array(
69
-                      strtoupper($content),
70
-                      strtolower($content),
71
-                      $content,
72
-                     );
69
+                        strtoupper($content),
70
+                        strtolower($content),
71
+                        $content,
72
+                        );
73 73
             $phpcsFile->addError($error, $stackPtr, 'FoundUppercase', $data);
74 74
         }
75 75
 
Please login to merge, or discard this patch.
src/Standards/Squiz/Sniffs/Functions/FunctionDeclarationSniff.php 1 patch
Indentation   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -57,7 +57,7 @@
 block discarded – undo
57 57
                 48 => 1,
58 58
                 70 => 1,
59 59
                 71 => 1,
60
-               );
60
+                );
61 61
 
62 62
     }//end getErrorList()
63 63
 
Please login to merge, or discard this patch.
src/Standards/Squiz/Sniffs/ControlStructures/ControlSignatureSniff.php 1 patch
Indentation   +7 added lines, -7 removed lines patch added patch discarded remove patch
@@ -32,9 +32,9 @@  discard block
 block discarded – undo
32 32
      * @var array
33 33
      */
34 34
     public $supportedTokenizers = array(
35
-                                   'PHP',
36
-                                   'JS',
37
-                                  );
35
+                                    'PHP',
36
+                                    'JS',
37
+                                    );
38 38
 
39 39
 
40 40
     /**
@@ -55,7 +55,7 @@  discard block
 block discarded – undo
55 55
                 T_ELSE,
56 56
                 T_ELSEIF,
57 57
                 T_SWITCH,
58
-               );
58
+                );
59 59
 
60 60
     }//end register()
61 61
 
@@ -92,9 +92,9 @@  discard block
 block discarded – undo
92 92
         if ($found !== 1) {
93 93
             $error = 'Expected 1 space after %s keyword; %s found';
94 94
             $data  = array(
95
-                      strtoupper($tokens[$stackPtr]['content']),
96
-                      $found,
97
-                     );
95
+                        strtoupper($tokens[$stackPtr]['content']),
96
+                        $found,
97
+                        );
98 98
 
99 99
             $fix = $phpcsFile->addFixableError($error, $stackPtr, 'SpaceAfterKeyword', $data);
100 100
             if ($fix === true) {
Please login to merge, or discard this patch.
src/Standards/Squiz/Sniffs/ControlStructures/LowercaseDeclarationSniff.php 1 patch
Indentation   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -44,7 +44,7 @@  discard block
 block discarded – undo
44 44
                 T_PRIVATE,
45 45
                 T_PROTECTED,
46 46
                 T_STATIC,
47
-               );
47
+                );
48 48
 
49 49
     }//end register()
50 50
 
@@ -66,10 +66,10 @@  discard block
 block discarded – undo
66 66
         if ($content !== strtolower($content)) {
67 67
             $error = '%s keyword must be lowercase; expected "%s" but found "%s"';
68 68
             $data  = array(
69
-                      strtoupper($content),
70
-                      strtolower($content),
71
-                      $content,
72
-                     );
69
+                        strtoupper($content),
70
+                        strtolower($content),
71
+                        $content,
72
+                        );
73 73
             $phpcsFile->addError($error, $stackPtr, 'FoundUppercase', $data);
74 74
         }
75 75
 
Please login to merge, or discard this patch.
src/Standards/Squiz/Sniffs/ControlStructures/ForLoopDeclarationSniff.php 2 patches
Indentation   +9 added lines, -9 removed lines patch added patch discarded remove patch
@@ -50,9 +50,9 @@  discard block
 block discarded – undo
50 50
      * @var array
51 51
      */
52 52
     public $supportedTokenizers = array(
53
-                                   'PHP',
54
-                                   'JS',
55
-                                  );
53
+                                    'PHP',
54
+                                    'JS',
55
+                                    );
56 56
 
57 57
 
58 58
     /**
@@ -106,9 +106,9 @@  discard block
 block discarded – undo
106 106
             if ($spaceAfterOpen !== $this->requiredSpacesAfterOpen) {
107 107
                 $error = 'Expected %s spaces after opening bracket; %s found';
108 108
                 $data  = array(
109
-                          $this->requiredSpacesAfterOpen,
110
-                          $spaceAfterOpen,
111
-                         );
109
+                            $this->requiredSpacesAfterOpen,
110
+                            $spaceAfterOpen,
111
+                            );
112 112
                 $fix   = $phpcsFile->addFixableError($error, $stackPtr, 'SpacingAfterOpen', $data);
113 113
                 if ($fix === true) {
114 114
                     $padding = str_repeat(' ', $this->requiredSpacesAfterOpen);
@@ -136,9 +136,9 @@  discard block
 block discarded – undo
136 136
             if ($this->requiredSpacesBeforeClose !== $spaceBeforeClose) {
137 137
                 $error = 'Expected %s spaces before closing bracket; %s found';
138 138
                 $data  = array(
139
-                          $this->requiredSpacesBeforeClose,
140
-                          $spaceBeforeClose,
141
-                         );
139
+                            $this->requiredSpacesBeforeClose,
140
+                            $spaceBeforeClose,
141
+                            );
142 142
                 $fix   = $phpcsFile->addFixableError($error, $stackPtr, 'SpacingBeforeClose', $data);
143 143
                 if ($fix === true) {
144 144
                     $padding = str_repeat(' ', $this->requiredSpacesBeforeClose);
Please login to merge, or discard this patch.
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -109,7 +109,7 @@  discard block
 block discarded – undo
109 109
                           $this->requiredSpacesAfterOpen,
110 110
                           $spaceAfterOpen,
111 111
                          );
112
-                $fix   = $phpcsFile->addFixableError($error, $stackPtr, 'SpacingAfterOpen', $data);
112
+                $fix = $phpcsFile->addFixableError($error, $stackPtr, 'SpacingAfterOpen', $data);
113 113
                 if ($fix === true) {
114 114
                     $padding = str_repeat(' ', $this->requiredSpacesAfterOpen);
115 115
                     if ($spaceAfterOpen === 0) {
@@ -139,7 +139,7 @@  discard block
 block discarded – undo
139 139
                           $this->requiredSpacesBeforeClose,
140 140
                           $spaceBeforeClose,
141 141
                          );
142
-                $fix   = $phpcsFile->addFixableError($error, $stackPtr, 'SpacingBeforeClose', $data);
142
+                $fix = $phpcsFile->addFixableError($error, $stackPtr, 'SpacingBeforeClose', $data);
143 143
                 if ($fix === true) {
144 144
                     $padding = str_repeat(' ', $this->requiredSpacesBeforeClose);
145 145
                     if ($spaceBeforeClose === 0) {
Please login to merge, or discard this patch.
src/Standards/Squiz/Sniffs/ControlStructures/SwitchDeclarationSniff.php 1 patch
Indentation   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -37,9 +37,9 @@  discard block
 block discarded – undo
37 37
      * @var array
38 38
      */
39 39
     public $supportedTokenizers = array(
40
-                                   'PHP',
41
-                                   'JS',
42
-                                  );
40
+                                    'PHP',
41
+                                    'JS',
42
+                                    );
43 43
 
44 44
     /**
45 45
      * The number of spaces code should be indented.
@@ -106,8 +106,8 @@  discard block
 block discarded – undo
106 106
                 $expected = strtolower($tokens[$nextCase]['content']);
107 107
                 $error    = strtoupper($type).' keyword must be lowercase; expected "%s" but found "%s"';
108 108
                 $data     = array(
109
-                             $expected,
110
-                             $tokens[$nextCase]['content'],
109
+                                $expected,
110
+                                $tokens[$nextCase]['content'],
111 111
                             );
112 112
 
113 113
                 $fix = $phpcsFile->addFixableError($error, $nextCase, $type.'NotLower', $data);
Please login to merge, or discard this patch.