Skip to content

Open-source event management and ticket selling platform — perfect for concerts, conferences, and everything in between 🎟️ If you find this project helpful, please consider giving us a star ⭐️

Fix error while marking offline order as paid. (#1007)

Dave Earleyd29814570b49
diff --git a/backend/app/Services/Domain/Order/MarkOrderAsPaidService.php b/backend/app/Services/Domain/Order/MarkOrderAsPaidService.php
index 32e76a4ce..e04a5f918 100644
--- a/backend/app/Services/Domain/Order/MarkOrderAsPaidService.php
+++ b/backend/app/Services/Domain/Order/MarkOrderAsPaidService.php
@@ -182,7 +182,7 @@ class MarkOrderAsPaidService
applicationFeeAmountMinorUnit: $this->orderApplicationFeeCalculationService->calculateApplicationFee(
accountConfiguration: $config,
order: $updatedOrder,
- )->netApplicationFee->toMinorUnit(),
+ )?->netApplicationFee?->toMinorUnit() ?? 0,
orderApplicationFeeStatus: OrderApplicationFeeStatus::AWAITING_PAYMENT,
paymentMethod: PaymentProviders::OFFLINE,
currency: $updatedOrder->getCurrency(),