Merge branch 'trunk' into PCP-1429-device-data-not-available-error-message-is-showing-for-pay-upon-invoice

This commit is contained in:
emilicastells 2023-02-13 09:48:49 +01:00
commit 1f395701ed
No known key found for this signature in database
GPG key ID: 1520C07081754570
12 changed files with 305 additions and 32 deletions

View file

@ -148,6 +148,12 @@ class WCGatewayModule implements ModuleInterface {
if ( ! $wc_order instanceof WC_Order ) {
return;
}
/**
* The filter can be used to remove the rows with PayPal fees in WC orders.
*/
if ( ! apply_filters( 'woocommerce_paypal_payments_show_fees_on_order_admin_page', true, $wc_order ) ) {
return;
}
// phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped
echo $fees_renderer->render( $wc_order );