8000 minor #42533 Do not use str_starts_with in translation-status.php (He… · symfony/symfony@b2a24b1 · GitHub
[go: up one dir, main page]

Skip to content

Commit b2a24b1

Browse files
committed
minor #42533 Do not use str_starts_with in translation-status.php (Hendrik Luup)
This PR was merged into the 4.4 branch. Discussion ---------- Do not use str_starts_with in translation-status.php | Q | A | ------------- | --- | Branch? | 4.4 | Bug fix? | yes | New feature? | no | Deprecations? | no | Tickets | N/A | License | MIT | Doc PR | N/A `translation-status.php` is a standalone script that might be run with PHP version that is less than <8.0 where `str_starts_with` is not available. I propose that we revert the change that was made in #41576 instead of trying to load the polyfill somehow. Commits ------- 94d843f Do not use str_start_with
2 parents 7151ffe + 94d843f commit b2a24b1

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/Symfony/Component/Translation/Resources/bin/translation-status.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,7 @@
6262
continue;
6363
}
6464

65-
if (str_starts_with($argumentOrOption, '-')) {
65+
if (0 === strpos($argumentOrOption, '-')) {
6666
$config['verbose_output'] = true;
6767
} else {
6868
$config['locale_to_analyze'] = $argumentOrOption;

0 commit comments

Comments
 (0)
0