@@ -29,17 +29,13 @@ class GlobalExceptionSniff implements Sniff
2929{
3030 public const CODE_GLOBAL_EXCEPTION = 'GlobalException ' ;
3131
32- /**
33- * @return mixed[]
34- */
32+ /** @return mixed[] */
3533 public function register (): array
3634 {
3735 return [T_OPEN_TAG ];
3836 }
3937
40- /**
41- * @param int $openTagPointer
42- */
38+ /** @param int $openTagPointer */
4339 public function process (File $ phpcsFile , $ openTagPointer ): void
4440 {
4541 $ currentPointer = $ openTagPointer ;
@@ -86,7 +82,7 @@ public function process(File $phpcsFile, $openTagPointer): void
8682 $ classEndPointer = TokenHelper::findNextExcluding (
8783 $ phpcsFile ,
8884 $ classTokens ,
89- $ classStartPointer + 1
85+ $ classStartPointer + 1 ,
9086 ) - 1 ;
9187 if (!$ classEndPointer ) {
9288 continue ;
@@ -101,7 +97,7 @@ public function process(File $phpcsFile, $openTagPointer): void
10197 $ phpcsFile ->addError (
10298 sprintf ('Global exception "%s" used. It should be locally extended. ' , $ class ),
10399 $ currentPointer ,
104- self ::CODE_GLOBAL_EXCEPTION
100+ self ::CODE_GLOBAL_EXCEPTION ,
105101 );
106102 }
107103 } else {
@@ -114,7 +110,7 @@ public function process(File $phpcsFile, $openTagPointer): void
114110 $ phpcsFile ->addError (
115111 sprintf ('Global exception "%s" used. It should be locally extended. ' , $ class ),
116112 $ classStartPointer ,
117- self ::CODE_GLOBAL_EXCEPTION
113+ self ::CODE_GLOBAL_EXCEPTION ,
118114 );
119115 }
120116 }
0 commit comments