[wp-trac] [WordPress Trac] #44534: wp_debug_mode() does not turn off display_errors for REST requests
WordPress Trac
noreply at wordpress.org
Wed Dec 12 03:08:03 UTC 2018
#44534: wp_debug_mode() does not turn off display_errors for REST requests
---------------------------------+-----------------------
Reporter: chrisl27 | Owner: earnjam
Type: defect (bug) | Status: closed
Priority: normal | Milestone: 5.0
Component: REST API | Version: 4.5
Severity: normal | Resolution: fixed
Keywords: has-patch fixed-5.0 | Focuses: rest-api
---------------------------------+-----------------------
Changes (by jeremyfelt):
* status: reopened => closed
* resolution: => fixed
Comment:
In [changeset:"43983" 43983]:
{{{
#!CommitTicketReference repository="" revision="43983"
Load: Disable PHP errors for JSON requests
Because WP REST API requests aren't identified until `parse_request`, it's
impractical to reference the `REST_REQUEST` constant in `wp_debug_mode()`.
Instead, it's more helpful to assume that a request wanting a JSON
response probably doesn't want PHP errors breaking the response.
Merges [43730] to trunk.
Props chrisl27, duanestorey, earnjam.
Fixes #44534.
}}}
--
Ticket URL: <https://core.trac.wordpress.org/ticket/44534#comment:31>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list