[wp-trac] [WordPress Trac] #58275: PHPv81 preg_split deprecation error in convert_smilies function
WordPress Trac
noreply at wordpress.org
Tue May 9 11:11:27 UTC 2023
#58275: PHPv81 preg_split deprecation error in convert_smilies function
----------------------------+-----------------------------
Reporter: joostdekeijzer | Owner: (none)
Type: defect (bug) | Status: new
Priority: normal | Milestone: Awaiting Review
Component: Formatting | Version: trunk
Severity: normal | Keywords:
Focuses: |
----------------------------+-----------------------------
Running PHP 8.1 I get the following error:
`[09-May-2023 10:23:57 UTC] PHP Deprecated: preg_split(): Passing null to
parameter #2 ($subject) of type string is deprecated in /wp-
includes/formatting.php on line 3442`
A solution might be to test on the `$text` argument not being empty? But
when I do that I get a followup error:
`[09-May-2023 10:30:55 UTC] PHP Deprecated: str_replace(): Passing null
to parameter #3 ($subject) of type array|string is deprecated in /wp-
includes/formatting.php on line 3906`
(in wp_trim_excerpt).
--
Ticket URL: <https://core.trac.wordpress.org/ticket/58275>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list