Unsupported operand types: float + string
-
Hi there,
plugin developer of Germanized here. One of our joint users experiences an error syncing orders with JTL. The error does only occur when using a plugin which adjusts shipping taxes in a way, that multiple tax rates apply for a single shipping item (mixed carts).
Could you please replace L 268 in
woo-jtl-connector/src/Controllers/Order/CustomerOrderItem.php:$priceGross = $netPrice + $taxAmount;with:
$priceGross = $netPrice + (float) $taxAmount;The
$taxAmountvariable being created by looping$shippingItem->get_taxes()contains strings, not floats. Adding the string to the existing float leads to a PHP error.Cheers,
Dennis
The topic ‘Unsupported operand types: float + string’ is closed to new replies.