mirror of
https://github.com/woocommerce/woocommerce-paypal-payments.git
synced 2025-09-06 10:55:00 +08:00
better check if request id is empty
This commit is contained in:
parent
8392f955ef
commit
8ba75230be
1 changed files with 2 additions and 1 deletions
|
@ -223,7 +223,8 @@ class OrderEndpoint {
|
|||
'body' => wp_json_encode( $data ),
|
||||
);
|
||||
|
||||
$paypal_request_id = $paypal_request_id ?: $this->generate_request_id();
|
||||
$paypal_request_id = '' === $paypal_request_id ? $this->generate_request_id() : $paypal_request_id;
|
||||
|
||||
$args['headers']['PayPal-Request-Id'] = $paypal_request_id;
|
||||
if ( $this->bn_code ) {
|
||||
$args['headers']['PayPal-Partner-Attribution-Id'] = $this->bn_code;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue