Only show integrations subnav when there are multiple integrations.
This commit is contained in:
parent
05d5849a67
commit
1af90cd169
|
@ -51,11 +51,13 @@ class WC_Settings_Integrations extends WC_Settings_Page {
|
|||
$current_section = current( $integrations )->id;
|
||||
}
|
||||
|
||||
if ( sizeof( $integrations ) > 1 ) {
|
||||
foreach ( $integrations as $integration ) {
|
||||
$title = empty( $integration->method_title ) ? ucfirst( $integration->id ) : $integration->method_title;
|
||||
|
||||
$sections[ strtolower( $integration->id ) ] = esc_html( $title );
|
||||
}
|
||||
}
|
||||
|
||||
return apply_filters( 'woocommerce_get_sections_' . $this->id, $sections );
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue