Skip to content

Commit

Permalink
Merge pull request #322 from PHPCSStandards/feature/universal-separat…
Browse files Browse the repository at this point in the history
…efunctionsfromoo-minor-fix

Universal/SeparateFunctionsFromOO: simplify skipping the rest of the file
  • Loading branch information
jrfnl authored Nov 9, 2024
2 parents 2bd085a + 7b88c12 commit de21892
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions Universal/Sniffs/Files/SeparateFunctionsFromOOSniff.php
Original file line number Diff line number Diff line change
Expand Up @@ -81,8 +81,7 @@ public function register()
* @param int $stackPtr The position of the current token
* in the stack passed in $tokens.
*
* @return int|void Integer stack pointer to skip forward or void to continue
* normal file processing.
* @return int Integer stack pointer to skip forward.
*/
public function process(File $phpcsFile, $stackPtr)
{
Expand Down Expand Up @@ -185,6 +184,6 @@ public function process(File $phpcsFile, $stackPtr)
}

// Ignore the rest of the file.
return ($phpcsFile->numTokens + 1);
return $phpcsFile->numTokens;
}
}

0 comments on commit de21892

Please sign in to comment.