Skip to content

Commit

Permalink
DevKit updates for 3.x branch (#616)
Browse files Browse the repository at this point in the history
Co-authored-by: Vincent Langlet <[email protected]>
  • Loading branch information
SonataCI and VincentLanglet authored Jul 15, 2024
1 parent e6b5886 commit 686c619
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 5 deletions.
2 changes: 0 additions & 2 deletions rector.php
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,6 @@

use Rector\Config\RectorConfig;
use Rector\Php70\Rector\FunctionLike\ExceptionHandlerTypehintRector;
use Rector\PHPUnit\CodeQuality\Rector\Class_\AddSeeTestAnnotationRector;
use Rector\PHPUnit\CodeQuality\Rector\Class_\PreferPHPUnitThisCallRector;
use Rector\PHPUnit\Set\PHPUnitSetList;
use Rector\Set\ValueObject\LevelSetList;
Expand All @@ -40,7 +39,6 @@
$rectorConfig->importShortClasses(false);
$rectorConfig->skip([
ExceptionHandlerTypehintRector::class,
AddSeeTestAnnotationRector::class,
PreferPHPUnitThisCallRector::class,
]);
};
6 changes: 3 additions & 3 deletions src/Helper/BaseHelper.php
Original file line number Diff line number Diff line change
Expand Up @@ -85,19 +85,19 @@ public static function getICUDataVersion(): string
foreach ($info as $line) {
$results = [];

if (preg_match('/(ICU Data version|ICU version) => (.*)/', $line, $results) > 0) {
if (1 === preg_match('/(ICU Data version|ICU version) => (.*)/', $line, $results)) {
return $results[2];
}
}
} else {
foreach ($info as $line) {
$results = [];

if (preg_match('/(ICU Data version).*/', $line, $results) > 0) {
if (1 === preg_match('/(ICU Data version).*/', $line, $results)) {
return trim(strtolower(strip_tags($results[0])), 'ICU Data version');
}

if (preg_match('/(ICU version).*/', $line, $results) > 0) {
if (1 === preg_match('/(ICU version).*/', $line, $results)) {
return trim(strtolower(strip_tags($results[0])), 'icu version');
}
}
Expand Down

0 comments on commit 686c619

Please sign in to comment.