[wp-trac] [WordPress Trac] #51383: PHP error body class added for suppressed errors
WordPress Trac
noreply at wordpress.org
Tue Apr 26 04:00:01 UTC 2022
#51383: PHP error body class added for suppressed errors
-------------------------------------+-----------------------------
Reporter: desrosj | Owner: hellofromTonya
Type: defect (bug) | Status: reviewing
Priority: normal | Milestone: 6.0
Component: Administration | Version: 5.5
Severity: normal | Resolution:
Keywords: has-patch needs-refresh | Focuses:
-------------------------------------+-----------------------------
Changes (by peterwilsoncc):
* keywords: has-patch needs-testing => has-patch needs-refresh
Comment:
I don't think the patch is correct.
The PHP class ought to be added if the warning is unsuppressed but with
the [https://github.com/WordPress/wordpress-develop/pull/2490 linked pull
request] the class is never displayed.
As a proof of concept, apply the patch and add `trigger_error( 'some
warning', E_WARNING );` prior to the definition of `$error_get_last`.
The warning will be displayed but the class won't be added to the `body`
element.
Developer types: remember to deactivate Query Monitor while testing this,
it sets an error handler that may trigger a few minutes confusion.
--
Ticket URL: <https://core.trac.wordpress.org/ticket/51383#comment:29>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list