[wp-trac] [WordPress Trac] #50913: PHP 8.0: various compatibility fixes
WordPress Trac
noreply at wordpress.org
Wed Sep 16 01:33:56 UTC 2020
#50913: PHP 8.0: various compatibility fixes
-------------------------------------------+-------------------------------
Reporter: jrf | Owner: SergeyBiryukov
Type: task (blessed) | Status: reviewing
Priority: normal | Milestone: 5.6
Component: General | Version:
Severity: normal | Resolution:
Keywords: php8 has-patch needs-dev-note | Focuses: coding-standards
-------------------------------------------+-------------------------------
Comment (by SergeyBiryukov):
In [changeset:"48979" 48979]:
{{{
#!CommitTicketReference repository="" revision="48979"
Tests: Revert [48973].
These tests ensure that a `_doing_it_wrong()` notice is thrown when
`wpdb::prepare()` is called incorrectly, but also that the function will
still handle the provided input as correctly as possible.
Disabling these tests on PHP 8 hides a problem, i.e. the function will no
longer throw a notice and handle things correctly, it will now cause a
white screen of death due to a fatal error.
That is a backward compatibility break, and `wpdb::prepare()` should be
updated instead to maintain the original behaviour on PHP 8.
Props jrf, ayeshrajans.
See #50913, #50639.
}}}
--
Ticket URL: <https://core.trac.wordpress.org/ticket/50913#comment:30>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list