diff --git a/ocean-extra.php b/ocean-extra.php index fcb0fee..074c95f 100644 --- a/ocean-extra.php +++ b/ocean-extra.php @@ -118,10 +118,15 @@ public function __construct( $widget_areas = array() ) { if ( ! is_child_theme() ) { $current_theme_version = theme_version(); } else { - $current_theme_version = '3.3.3'; + $parent = wp_get_theme()->parent(); + // get parent version + if ( ! empty( $parent) ) { + $current_theme_version = $parent->Version; + } } $required_theme_version = '3.3.3'; + require_once OE_PATH . '/includes/panel/theme-panel.php'; require_once OE_PATH . '/includes/panel/integrations-tab.php'; $oe_library_active_status = get_option( 'oe_library_active_status', 'yes' ); @@ -135,7 +140,7 @@ public function __construct( $widget_areas = array() ) { require_once OE_PATH . '/includes/themepanel/theme-panel.php'; - if ( ! empty( $current_theme_version ) && ! empty( $required_theme_version ) && version_compare( $current_theme_version, $required_theme_version , '>=' ) ) { + if ( ! empty( $current_theme_version ) && ! empty( $required_theme_version ) && version_compare( $current_theme_version, $required_theme_version , '>' ) ) { require_once OE_PATH . '/includes/compatibility/ocean.php'; }