Fix Pint formatting

This commit is contained in:
root
2026-06-09 01:25:14 -04:00
parent 6be4875c5e
commit 20a0b6c4e5
1485 changed files with 11318 additions and 10273 deletions
+6 -7
View File
@@ -14,8 +14,7 @@ class RefundPolicyService
public function __construct(
private FeeRefundDetailService $refundDetails,
private RefundInvoiceAdjustmentService $invoiceAdjustments
) {
}
) {}
public function processWithdrawalRefund(
int $parentId,
@@ -39,7 +38,7 @@ class RefundPolicyService
->orderByDesc('created_at')
->first();
if (!$invoice) {
if (! $invoice) {
return ['ok' => false, 'error' => 'No invoice found for refund processing.'];
}
@@ -116,14 +115,14 @@ class RefundPolicyService
$refundAmount = (float) ($details['refund_amount'] ?? 0.0);
$debitAmount = (float) ($details['debit_amount'] ?? 0.0);
$eligible = !empty($details['eligible']);
$eligible = ! empty($details['eligible']);
$status = $refundAmount > 0 ? Refund::STATUS_PENDING : Refund::STATUS_REJECTED;
$reason = null;
if ($refundAmount <= 0) {
if (!$eligible) {
if (! $eligible) {
$reason = 'No refund due to late withdrawal.';
} elseif (!empty($details['full_discount'])) {
} elseif (! empty($details['full_discount'])) {
$reason = 'No refund due to full discount.';
} elseif ($debitAmount > 0) {
$reason = 'No refund due; book fee balance remains.';
@@ -189,7 +188,7 @@ class RefundPolicyService
'updated_by' => $actorId,
]);
if (!$created) {
if (! $created) {
return ['ok' => false, 'error' => 'Failed to create refund record.'];
}