TASK: Fix call to undefined method

Relates: #33
This commit is contained in:
Daniel Siepmann 2017-03-21 13:43:52 +01:00
parent 9a13223d62
commit 0d985ef42a
Signed by: Daniel Siepmann
GPG key ID: 33D6629915560EF4

View file

@ -101,7 +101,7 @@ abstract class AbstractClassnameChecker implements PhpCsSniff
$tokens = $phpcsFile->getTokens();
$classnamePosition = $phpcsFile->findNext(T_STRING, $stackPtr);
if ($this->findPrev()) {
if ($this->shouldLookBefore()) {
$classnamePosition = $phpcsFile->findPrevious(T_STRING, $stackPtr);
}
if ($classnamePosition === false) {