WordPress.org

Make WordPress Core

Ticket #27897: 27897.patch

File 27897.patch, 780 bytes (added by ocean90, 4 years ago)
  • src/wp-includes/widgets.php

     
    14211421                // time() that sidebars were stored is in $old_sidebars_widgets['time'] 
    14221422                $_sidebars_widgets = $old_sidebars_widgets['data']; 
    14231423 
    1424                 if ( 'customize' === $theme_changed ) { 
     1424                if ( 'customize' !== $theme_changed ) { 
    14251425                        remove_theme_mod( 'sidebars_widgets' ); 
    14261426                } 
    14271427 
     
    15061506        } 
    15071507 
    15081508        $sidebars_widgets['wp_inactive_widgets'] = array_merge($lost_widgets, (array) $sidebars_widgets['wp_inactive_widgets']); 
    1509         if ( 'customize' === $theme_changed ) { 
     1509        if ( 'customize' !== $theme_changed ) { 
    15101510                wp_set_sidebars_widgets( $sidebars_widgets ); 
    15111511        } 
    15121512