Skip to content
This repository has been archived by the owner on Dec 3, 2023. It is now read-only.

Commit

Permalink
[EasyCodingStandard] fix skipping code even on --fix [closes #422]
Browse files Browse the repository at this point in the history
  • Loading branch information
TomasVotruba committed Nov 14, 2017
1 parent 98bc338 commit 75ae682
Showing 1 changed file with 5 additions and 0 deletions.
Expand Up @@ -120,6 +120,11 @@ public function getErrors(): void
*/
public function addFixableError($error, $stackPtr, $code, $data = [], $severity = 0): bool
{
$fullyQualifiedCode = $this->currentSniffProvider->getSniffClass() . '.' . $code;
if ($this->skipper->shouldSkipCodeAndFile($fullyQualifiedCode, $this->path)) {
return false;
}

$this->addError($error, $stackPtr, $code, $data, $severity, true);

return $this->isFixer;
Expand Down

0 comments on commit 75ae682

Please sign in to comment.