Skip to content

Commit 04b2004

Browse files
committed
minor #4546 DX: removing unnecessary variable initialization (kubawerlos)
This PR was merged into the 2.15 branch. Discussion ---------- DX: removing unnecessary variable initialization Spotted when working on kubawerlos/php-cs-fixer-custom-fixers#132 Both variables will be initialized in `if` and in `else`. Commits ------- bbd94b0 DX: removing unnecessary variable initialization
2 parents 7a68ba5 + bbd94b0 commit 04b2004

File tree

1 file changed

+0
-2
lines changed

1 file changed

+0
-2
lines changed

src/Fixer/PhpUnit/PhpUnitTestClassRequiresCoversFixer.php

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -88,8 +88,6 @@ private function addRequiresCover(Tokens $tokens, $startIndex)
8888
: '';
8989

9090
$prevIndex = $tokens->getPrevNonWhitespace($index);
91-
$doc = null;
92-
$docIndex = null;
9391

9492
if ($tokens[$prevIndex]->isGivenKind(T_DOC_COMMENT)) {
9593
$docIndex = $prevIndex;

0 commit comments

Comments
 (0)