Deprecate MD_STD::startsWith - can be replaced by str_starts_with
This commit is contained in:
parent
01ac23229b
commit
7fb5ad8ced
@ -135,6 +135,7 @@ final class MD_STD {
|
||||
|
||||
/**
|
||||
* Function checking if a string starts with another.
|
||||
* DEPRECATED. Can be replaced by PHP8's str_starts_with.
|
||||
*
|
||||
* @param string $haystack String to check.
|
||||
* @param string $needle Potential start of $haystack.
|
||||
@ -164,7 +165,7 @@ final class MD_STD {
|
||||
|
||||
$output = false;
|
||||
foreach ($needles as $needle) {
|
||||
$output = self::startsWith($haystack, $needle);
|
||||
$output = \str_starts_with($haystack, $needle);
|
||||
if ($output == true) {
|
||||
return $output;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user