Opened 8 years ago
Closed 8 years ago
#41252 closed defect (bug) (fixed)
Customize: WP_Customize_Manager::save_changeset_post() can fail if get_changeset_post_data method returns WP_Error
Reported by: |
|
Owned by: |
|
---|---|---|---|
Milestone: | 4.9 | Priority: | normal |
Severity: | normal | Version: | 4.7 |
Component: | Customize | Keywords: | has-patch has-unit-tests commit |
Focuses: | Cc: |
Description
If a changeset post is corrupted, then \WP_Customize_Manager::get_changeset_post_data()
will return a WP_Error
. This method is used by \WP_Customize_Manager::save_changeset_post()
to obtain an existing changeset's post data to merge on top of. However, it is not doing the necessary check to see if it is returning a WP_Error
, and thus results in a fatal error:
PHP Fatal error: Cannot use object of type WP_Error as array in wp-includes/class-wp-customize-manager.php on line 2334
Attachments (1)
Change History (4)
Note: See
TracTickets for help on using
tickets.
https://github.com/xwp/wordpress-develop/pull/238