mirror of
https://github.com/gosticks/wordpress-develop.git
synced 2026-06-28 14:20:15 +00:00
Customize: Handle filtering sidebars_widgets when the underlying option is non-existent.
Fixes warning related to a non-array argument for `array_merge()` in `WP_Customize_Widgets::customize_register()`. See [37166]. See #36389. Fixes #36660. git-svn-id: https://develop.svn.wordpress.org/trunk@37352 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
@@ -1064,7 +1064,7 @@ final class WP_Customize_Widgets {
|
||||
* @return array
|
||||
*/
|
||||
public function preview_sidebars_widgets( $sidebars_widgets ) {
|
||||
$sidebars_widgets = get_option( 'sidebars_widgets' );
|
||||
$sidebars_widgets = get_option( 'sidebars_widgets', array() );
|
||||
|
||||
unset( $sidebars_widgets['array_version'] );
|
||||
return $sidebars_widgets;
|
||||
|
||||
Reference in New Issue
Block a user