Skip to content
This repository has been archived by the owner on Sep 23, 2024. It is now read-only.

Commit

Permalink
Merge pull request #12 from ultrapremiumdirect/mt/fix/BACK-679
Browse files Browse the repository at this point in the history
fix: (BACK-679) corrige un problème de cast de donnée
  • Loading branch information
Grégoire Bélorgey authored Apr 1, 2022
2 parents 290a211 + cf0eee8 commit e4e6530
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/Controller/Webhook/CheckoutOrderApprovedAction.php
Original file line number Diff line number Diff line change
Expand Up @@ -91,7 +91,7 @@ public function __invoke(Request $request): Response
$details = $this->orderDetailsApi->get($token, $data['id']);

$order = $payment->getOrder();
$totalPaypal = (int) $details['purchase_units'][0]['amount']['value'] * 100;
$totalPaypal = (int) ($details['purchase_units'][0]['amount']['value'] * 100);

// Update payment total with the Paypal total (partially paid state will be triggered)
if ($totalPaypal != $order->getTotal()) {
Expand Down

0 comments on commit e4e6530

Please sign in to comment.