Skip to content

Commit ba601f6

Browse files
committed
clean up
1 parent 02c004e commit ba601f6

3 files changed

Lines changed: 2 additions & 7 deletions

File tree

src/ChangesReporting/Output/ConsoleOutputFormatter.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -146,7 +146,7 @@ private function createSuccessMessage(ProcessResult $processResult, Configuratio
146146
{
147147
$changeCount = $processResult->getTotalChanged();
148148

149-
if ($changeCount === 0 && ! $processResult->hasChanged()) {
149+
if ($changeCount === 0) {
150150
return 'Rector is done!';
151151
}
152152

src/Console/Command/ProcessCommand.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -214,7 +214,7 @@ private function resolveReturnCode(ProcessResult $processResult, Configuration $
214214
return ExitCode::CHANGED_CODE;
215215
}
216216

217-
if ($processResult->hasChanged()) {
217+
if ($processResult->getTotalChanged() > 0) {
218218
return ExitCode::CHANGED_CODE;
219219
}
220220

src/ValueObject/ProcessResult.php

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -53,11 +53,6 @@ public function addSystemErrors(array $systemErrors): void
5353
$this->systemErrors = [...$this->systemErrors, ...$systemErrors];
5454
}
5555

56-
public function hasChanged(): bool
57-
{
58-
return $this->totalChanged > 0;
59-
}
60-
6156
public function getTotalChanged(): int
6257
{
6358
return $this->totalChanged;

0 commit comments

Comments
 (0)