woocommerce_is_downloadable
Checks if a product is downloadable.
Usage
add_filter( 'woocommerce_is_downloadable', 'wp_kama_woocommerce_is_downloadable_filter', 10, 2 ); /** * Function for `woocommerce_is_downloadable` filter-hook. * * @param $true === $this->get_downloadable * @param $that * * @return */ function wp_kama_woocommerce_is_downloadable_filter( $true === $this->get_downloadable, $that ){ // filter... return $true === $this->get_downloadable; }
- $true === $this->get_downloadable
- -
- $that
- -
Where the hook is called
woocommerce_is_downloadable
woocommerce/includes/abstracts/abstract-wc-product.php 1584
return apply_filters( 'woocommerce_is_downloadable', true === $this->get_downloadable(), $this );