mirror of
https://github.com/WordPress/WordPress.git
synced 2024-11-14 14:45:45 +01:00
94a93212ba
This fixes a bug where widgets are unintentionally moved to the `wp_inactive_widgets` sidebar when batch updates occur through the REST API. When batch requests are processed, only `$_wp_sidebars_widgets` is updated by previous calls to `WP_REST_Widgets_Controller::create_item()`. `$sidebars_widgets` is not aware of the new widget’s intended location, and `retrieve_widgets()` mistakenly flags the widget as inactive. Calling `wp_get_sidebars_widgets()` before `retrieve_widgets()` ensures both global variables match and is intended as a temporary fix until the root cause of the problem can be fixed. Props zieladam, htmgarcia, timothyblynjacobs. Merges [51432] to the 5.8 branch. Fixes #53657. Built from https://develop.svn.wordpress.org/branches/5.8@51439 git-svn-id: http://core.svn.wordpress.org/branches/5.8@51050 1a063a9b-81f0-0310-95a4-ce76da25c4cd |
||
---|---|---|
.. | ||
endpoints | ||
fields | ||
search | ||
class-wp-rest-request.php | ||
class-wp-rest-response.php | ||
class-wp-rest-server.php |