Automattic\WooCommerce\Blocks\Payments\Integrations
CashOnDelivery::get_enable_for_virtual()
Return enable_for_virtual option.
Method of the class: CashOnDelivery{}
No Hooks.
Return
true|false
. True if store allows COD payment for orders containing only virtual products.
Usage
// private - for code of main (parent) class only $result = $this->get_enable_for_virtual();
CashOnDelivery::get_enable_for_virtual() CashOnDelivery::get enable for virtual code WC 8.7.0
private function get_enable_for_virtual() { return filter_var( $this->get_setting( 'enable_for_virtual', false ), FILTER_VALIDATE_BOOLEAN ); }