Automattic\WooCommerce\Admin\API
ShippingPartnerSuggestions::should_display
Check if suggestions should be shown in the settings screen.
Method of the class: ShippingPartnerSuggestions{}
Hooks from the method
Returns
true|false
.
Usage
// private - for code of main (parent) class only $result = $this->should_display();
ShippingPartnerSuggestions::should_display() ShippingPartnerSuggestions::should display code WC 9.9.5
private function should_display() { if ( 'no' === get_option( 'woocommerce_show_marketplace_suggestions', 'yes' ) ) { return false; } /** * The return value can be controlled via woocommerce_allow_shipping_partner_suggestions filter. * * @since 7.4.1 */ return apply_filters( 'woocommerce_allow_shipping_partner_suggestions', true ); }