Order_Endpoint::get_error_messages()
Returns an array of error messages that are used by the API responses.
Return
(array) $messages Array of error messages.
Source
File: src/Tickets/Commerce/Gateways/PayPal/REST/Order_Endpoint.php
public function get_error_messages() {
$messages = [
'failed-creating-order' => __( 'Creating new PayPal order failed. Please try again.', 'event-tickets' ),
'canceled-creating-order' => __( 'Your PayPal order was cancelled.', 'event-tickets' ),
'nonexistent-order-id' => __( 'Provided Order id is not valid.', 'event-tickets' ),
'failed-capture' => __( 'There was a problem while processing your payment, please try again.', 'event-tickets' ),
'invalid-capture-status' => __( 'There was a problem with the Order status change, please try again.', 'event-tickets' ),
];
/**
* Filter the error messages for PayPal checkout.
*
* @since 5.2.0
*
* @param array $messages Array of error messages.
*/
return apply_filters( 'tec_tickets_commerce_order_endpoint_error_messages', $messages );
}
Changelog
| Version | Description |
|---|---|
| 5.2.0 | Introduced. |