Automattic\WooCommerce\Blocks\Payments\Integrations
CashOnDelivery::get_enable_for_methods()
Return enable_for_methods option.
Method of the class: CashOnDelivery{}
No Hooks.
Return
Array
. Array of shipping methods (string ids) that allow COD. (If empty, all support COD.)
Usage
// private - for code of main (parent) class only $result = $this->get_enable_for_methods();
CashOnDelivery::get_enable_for_methods() CashOnDelivery::get enable for methods code WC 9.2.3
private function get_enable_for_methods() { $enable_for_methods = $this->get_setting( 'enable_for_methods', [] ); if ( '' === $enable_for_methods ) { return []; } return $enable_for_methods; }