Merge branch 'trunk' into PCP-591-save-and-display-vaulted-payment-methods-in-woo-commerce-native-endpoint

This commit is contained in:
emilicastells 2023-01-24 09:48:29 +01:00
commit d558f0db5c
No known key found for this signature in database
GPG key ID: 1520C07081754570
6 changed files with 24 additions and 0 deletions

View file

@ -236,6 +236,10 @@ class OrderEndpoint {
$args['headers']['PayPal-Client-Metadata-Id'] = $this->fraudnet->session_id();
}
if ( isset( $data['payment_source'] ) ) {
$args['headers']['PayPal-Request-Id'] = uniqid( 'ppcp-', true );
}
$response = $this->request( $url, $args );
if ( is_wp_error( $response ) ) {
$error = new RuntimeException(