Skip to content

Commit b02031b

Browse files
committed
style: compliance with rector rules
1 parent 4555d88 commit b02031b

File tree

1 file changed

+5
-4
lines changed

1 file changed

+5
-4
lines changed

system/Commands/Translation/LocalizationFinder.php

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,9 @@
2020
use RecursiveIteratorIterator;
2121
use SplFileInfo;
2222

23+
/**
24+
* @see \CodeIgniter\Commands\Translation\LocalizationFinderTest
25+
*/
2326
class LocalizationFinder extends BaseCommand
2427
{
2528
protected $group = 'Translation';
@@ -254,10 +257,8 @@ private function replaceArraySyntax(string $code): string
254257
}
255258

256259
// Replace indent
257-
if ($tokenId === T_WHITESPACE) {
258-
if (preg_match('/\n([ ]+)/u', $tokenValue, $matches)) {
259-
$newTokens[$i][1] = "\n{$matches[1]}{$matches[1]}";
260-
}
260+
if ($tokenId === T_WHITESPACE && preg_match('/\n([ ]+)/u', $tokenValue, $matches)) {
261+
$newTokens[$i][1] = "\n{$matches[1]}{$matches[1]}";
261262
}
262263
} // Replace ")"
263264
elseif ($token === ')') {

0 commit comments

Comments
 (0)