gform_ppcp_entry_not_found_status_code

Description

The “gform_ppcp_entry_not_found_status_code” filter in the Gravity Forms PayPal Checkout Add-On allows the status code for the entry not found WP_Error to be overridden.

Usage

add_filter( 'gform_ppcp_entry_not_found_status_code', 'your_function_name', 10, 3 );

Parameters

  • $status_code int

    The status code. Default is 200.

  • $action array

    An associative array containing the event details.

    array(
            'type'             => '',
            'amount'           => '',
            'transaction_type' => '',
            'transaction_id'   => '',
            'subscription_id'  => '',
            'entry_id'         => '',
            'payment_status'   => '',
            'note'             => '',
    );
    

  • $event array

    The PayPal event object for the webhook which was received. See the PayPal API Reference for details about the event properties.

Examples

add_filter( 'gform_ppcp_entry_not_found_status_code', 'change_status_code', 10, 3 );
function change_status_code( $status_code, $action, $event ) {
	return '205';
}

Placement

This code should be placed in the functions.php file of your active theme.

Source Code

This filter is located in GF_PPCP::get_entry_not_found_wp_error() in gravityformsstripe/class-gf-ppcp.php.