#46620 closed enhancement (fixed)
WSoD Protection: Pass the error through to error template and associated filters
| Reported by: |
|
Owned by: |
|
|---|---|---|---|
| Milestone: | 5.2 | Priority: | normal |
| Severity: | normal | Version: | 5.2 |
| Component: | Plugins | Keywords: | has-patch |
| Focuses: | Cc: |
Description
This change passes the error data through the error template handler, so it's exposed to the custom error handler if present, and through the default error template handler, so it's exposed to the default error message filters and the ultimate WP_Error object that's passed to wp_die().
This has a few benefits:
- The custom error handler and default error message filters can inspect the error and perform logic based on its properties.
- Custom
wp_die()handlers can alter their behaviour depending on a combination of the error itself and the WP_Error code. For example, WP-CLI could more gracefully handle this error in its output by including details of the error itself and information about enabling recovery mode or using WP-CLI's own--skip-pluginsflag.
Taken from https://github.com/wp-core-php/wordpress-develop/pull/7
Attachments (1)
Change History (4)
Note: See
TracTickets for help on using
tickets.
In 45023: