Merged in feature/MAW-855-import-code-into-aws (pull request #2)

code import from pantheon

* code import from pantheon
This commit is contained in:
Tony Volpe
2023-12-04 23:08:14 +00:00
parent 8c9b1312bc
commit 8f4b5efda6
4766 changed files with 185592 additions and 239967 deletions

View File

@@ -1046,6 +1046,11 @@ class WC_Checkout {
// Store Order ID in session so it can be re-used after payment failure.
WC()->session->set( 'order_awaiting_payment', $order_id );
// We save the session early because if the payment gateway hangs
// the request will never finish, thus the session data will neved be saved,
// and this can lead to duplicate orders if the user submits the order again.
WC()->session->save_data();
// Process Payment.
$result = $available_gateways[ $payment_method ]->process_payment( $order_id );
@@ -1291,7 +1296,7 @@ class WC_Checkout {
* Get a posted address field after sanitization and validation.
*
* @param string $key Field key.
* @param string $type Type of address. Available options: 'billing' or 'shipping'.
* @param string $type Type of address; 'billing' or 'shipping'.
* @return string
*/
public function get_posted_address_data( $key, $type = 'billing' ) {