From e26803edaa56ab1b0c90ad39b423868f13622e7d Mon Sep 17 00:00:00 2001 From: raducretu Date: Mon, 29 Jul 2019 19:54:47 +0300 Subject: [PATCH] v2.4.4 --- class.sidebars.php | 14 ++++++++++---- curly-extension.php | 3 ++- 2 files changed, 12 insertions(+), 5 deletions(-) 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 '