Merge pull request #2246 from entr/patch-2
Issue #2245 / Disable Integrations Tab if empty
This commit is contained in:
commit
93e55e19e0
|
@ -227,6 +227,9 @@ if ( ! function_exists( 'woocommerce_settings' ) ) {
|
||||||
'integration' => __( 'Integration', 'woocommerce' )
|
'integration' => __( 'Integration', 'woocommerce' )
|
||||||
);
|
);
|
||||||
|
|
||||||
|
if ( ! count( $woocommerce->integrations->get_integrations() ) )
|
||||||
|
unset( $tabs['integration'] );
|
||||||
|
|
||||||
$tabs = apply_filters('woocommerce_settings_tabs_array', $tabs);
|
$tabs = apply_filters('woocommerce_settings_tabs_array', $tabs);
|
||||||
|
|
||||||
foreach ( $tabs as $name => $label ) {
|
foreach ( $tabs as $name => $label ) {
|
||||||
|
|
Loading…
Reference in New Issue