Add filter for the total

This commit is contained in:
Narek Zakarian 2024-07-09 15:40:16 +04:00
parent cb624eb3bf
commit 0038922fe8
No known key found for this signature in database
GPG key ID: 07AFD7E7A9C164A7

View file

@ -131,6 +131,7 @@ class WooCommerceOrderCreator {
}
$total = $product->get_price() * $quantity;
$total = apply_filters( 'woocommerce_paypal_payments_shipping_callback_cart_line_item_total', $total, $cart_item );
$item->set_name( $product->get_name() );
$item->set_subtotal( $total );