woocommerce_max_webhook_delivery_failures

woocommerce_max_webhook_delivery_failures

Appears in: , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , ,
Hook Type: filter

See hook in core

Displaying hooks found in version: woocommerce.9.8.1

apply_filters('woocommerce_max_webhook_delivery_failures') is found 1 times:

  • /includes/class-wc-webhook.php line 556
    552
    553
    554
    555
    556
    557
    558
    559
    560
    561
    562
    */
    private function failed_delivery() {
        $failures = $this->get_failure_count();
     
        if ( $failures > apply_filters( 'woocommerce_max_webhook_delivery_failures', 5 ) ) {
            $this->set_status( 'disabled' );
     
            do_action( 'woocommerce_webhook_disabled_due_delivery_failures', $this->get_id() );
        } else {
            $this->set_failure_count( ++$failures );
        }