[wp-trac] [WordPress Trac] #43502: `WP_REST_Posts_Controller::prepare_item_for_response()` doesn't reset postdata after calling setup_postdata()
WordPress Trac
noreply at wordpress.org
Fri Jun 9 11:19:36 UTC 2023
#43502: `WP_REST_Posts_Controller::prepare_item_for_response()` doesn't reset
postdata after calling setup_postdata()
-------------------------------------------------+-------------------------
Reporter: gerbenvandijk | Owner: (none)
Type: defect (bug) | Status: new
Priority: normal | Milestone: Future
| Release
Component: REST API | Version: 4.9.4
Severity: normal | Resolution:
Keywords: good-first-bug has-patch needs- | Focuses: rest-api
testing has-unit-tests |
-------------------------------------------------+-------------------------
Comment (by elenachavdarova):
Hi,
In https://github.com/WordPress/wordpress-develop/pull/4591, I have
included tests for the changes from this PR: https://github.com/WordPress
/wordpress-develop/pull/1165
However I want to mention that the post data is still not being reverted
even with the wp_reset_postdata() action added to the methods.
--
Ticket URL: <https://core.trac.wordpress.org/ticket/43502#comment:21>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list