Created
November 8, 2021 15:47
-
-
Save dparker1005/65d377b4580c4ca896cbff43a9128129 to your computer and use it in GitHub Desktop.
Disables the `pmpro_send_200_http_response()` function.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
// Copy from below here... | |
/** | |
* Disables the `pmpro_send_200_http_response()` function. | |
* | |
* That function was implemented in PMPro v2.6.4 to allow IPN/webhook | |
* handlers to adknowledge the receipt of a webhook before processing | |
* it in order to avoid timeout issues at the gateway. | |
* | |
* This code recipe should be used in cases where gateways are showing that | |
* PMPro returned an error for a webhook, even though the webhook was processed properly. | |
* | |
* You can add this recipe to your site by creating a custom plugin | |
* or using the Code Snippets plugin available for free in the WordPress repository. | |
* Read this companion article for step-by-step directions on either method. | |
* https://www.paidmembershipspro.com/create-a-plugin-for-pmpro-customizations/ | |
*/ | |
add_filter( 'pmpro_send_200_http_response', '__return_false' ); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment