Answers for "New value type (null) is not matching the resolved parameter type"

0

New value type (null) is not matching the resolved parameter type

preg_replace can return 'string|string[]|null', hence the warning is there.
What about $text = (string) preg_replace(...) 
(you are not handling null-value anyway)
Posted by: Guest on January-27-2021

Code answers related to "New value type (null) is not matching the resolved parameter type"

Browse Popular Code Answers by Language