Skip to content

Commit 456e989

Browse files
minor symfony#60216 Fix detection of component_bridge in .github/get-modified-packages.php (GromNaN)
This PR was merged into the 7.2 branch. Discussion ---------- Fix detection of `component_bridge` in `.github/get-modified-packages.php` | Q | A | ------------- | --- | Branch? | 7.2 | Bug fix? | no | New feature? | no | Deprecations? | no | Issues | - | License | MIT > `preg_match()` returns `1` if the pattern matches given subject, `0` if it does not, or `false` on failure. And > A `match` arm compares values strictly (`===`) This change was introduced into 7.1 by symfony@e290334. Commits ------- 068f863 Fix get-modified-packages for component_bridge
2 parents fd0d3c0 + 068f863 commit 456e989

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

.github/get-modified-packages.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ function getPackageType(string $packageDir): string
2222
return match (true) {
2323
str_contains($packageDir, 'Symfony/Bridge/') => 'bridge',
2424
str_contains($packageDir, 'Symfony/Bundle/') => 'bundle',
25-
preg_match('@Symfony/Component/[^/]+/Bridge/@', $packageDir) => 'component_bridge',
25+
1 === preg_match('@Symfony/Component/[^/]+/Bridge/@', $packageDir) => 'component_bridge',
2626
str_contains($packageDir, 'Symfony/Component/') => 'component',
2727
str_contains($packageDir, 'Symfony/Contracts/') => 'contract',
2828
str_ends_with($packageDir, 'Symfony/Contracts') => 'contracts',

0 commit comments

Comments
 (0)