From 8646dfbf02d9817c6f63cbec72085d2e363e5a40 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bj=C3=B6rn=20Fromme?= Date: Wed, 7 Jan 2026 18:46:28 +0100 Subject: [PATCH] fix: avoid float rounding errors when comparing --- src/Controller/Booking/Create/Step3Controller.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Controller/Booking/Create/Step3Controller.php b/src/Controller/Booking/Create/Step3Controller.php index 6f9a652..9deaaa7 100644 --- a/src/Controller/Booking/Create/Step3Controller.php +++ b/src/Controller/Booking/Create/Step3Controller.php @@ -122,7 +122,7 @@ class Step3Controller extends AbstractController $promoGoodwillDiscount = round($inquiryResponse->getVoucherDiscountFromPrices(), 2); $expectedTotal = round($calculatedSubtotal - $promoGoodwillDiscount, 2); - if ($apiTotal !== $expectedTotal) { + if ((int) round($apiTotal * 100) !== (int) round($expectedTotal * 100)) { return $this->handleApiError( 'Price mismatch detected - payload incomplete', [