TASK: According to PR, use else instead of default
This commit is contained in:
parent
0d985ef42a
commit
f91d3240e5
1 changed files with 3 additions and 1 deletions
|
@ -100,10 +100,12 @@ abstract class AbstractClassnameChecker implements PhpCsSniff
|
|||
{
|
||||
$tokens = $phpcsFile->getTokens();
|
||||
|
||||
$classnamePosition = $phpcsFile->findNext(T_STRING, $stackPtr);
|
||||
if ($this->shouldLookBefore()) {
|
||||
$classnamePosition = $phpcsFile->findPrevious(T_STRING, $stackPtr);
|
||||
} else {
|
||||
$classnamePosition = $phpcsFile->findNext(T_STRING, $stackPtr);
|
||||
}
|
||||
|
||||
if ($classnamePosition === false) {
|
||||
return;
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue