mirror of
https://github.com/woocommerce/woocommerce-paypal-payments.git
synced 2025-09-10 12:00:32 +08:00
Catch correct exception
This commit is contained in:
parent
bb6e177ef3
commit
fa049527b6
1 changed files with 2 additions and 1 deletions
|
@ -9,6 +9,7 @@ declare(strict_types=1);
|
|||
|
||||
namespace WooCommerce\PayPalCommerce\ApiClient\Endpoint;
|
||||
|
||||
use Exception;
|
||||
use stdClass;
|
||||
use WooCommerce\PayPalCommerce\ApiClient\Authentication\Bearer;
|
||||
use WooCommerce\PayPalCommerce\ApiClient\Exception\PayPalApiException;
|
||||
|
@ -138,7 +139,7 @@ class BillingAgreementsEndpoint {
|
|||
}
|
||||
|
||||
return true;
|
||||
} catch ( PayPalApiException $exception ) {
|
||||
} catch ( Exception $exception ) {
|
||||
delete_transient( 'ppcp_reference_transaction_enabled' );
|
||||
return false;
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue