diff --git a/class.sidebars.php b/class.sidebars.php index 060621f..9390a94 100644 --- a/class.sidebars.php +++ b/class.sidebars.php @@ -218,9 +218,15 @@ public static function sidebar( $default = null, $logic = false, $return = false $sidebar = get_post_meta( $post->ID, 'white_dynamic_sidebar', true ); if( $return === true ){ - if ( $sidebar && is_active_sidebar( $sidebar ) ) return $sidebar; - elseif( is_active_sidebar( $default ) ) return $default; - else return; + if ( is_active_sidebar( $sidebar ) ){ + return $sidebar; + } + elseif( is_active_sidebar( $default ) ){ + return $default; + } + else { + return; + } } else { if ( $logic === true ) { if ( $sidebar && is_active_sidebar( $sidebar ) ) { @@ -269,7 +275,7 @@ public function meta_box_callback( $post ) { echo '
'; echo '