From eaf6d53d8c986e050308375a4f85b352332eb9ff Mon Sep 17 00:00:00 2001 From: David Bomba Date: Sat, 16 Oct 2021 12:02:17 +1100 Subject: [PATCH] Expense default amount --- app/Factory/RecurringExpenseToExpenseFactory.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/Factory/RecurringExpenseToExpenseFactory.php b/app/Factory/RecurringExpenseToExpenseFactory.php index 76a3b0456e..bd8bc65164 100644 --- a/app/Factory/RecurringExpenseToExpenseFactory.php +++ b/app/Factory/RecurringExpenseToExpenseFactory.php @@ -38,7 +38,7 @@ class RecurringExpenseToExpenseFactory $expense->date = now()->format('Y-m-d'); $expense->payment_date = $recurring_expense->payment_date; $expense->amount = $recurring_expense->amount; - $expense->foreign_amount = $recurring_expense->foreign_amount; + $expense->foreign_amount = $recurring_expense->foreign_amount ?: 0; $expense->private_notes = $recurring_expense->private_notes; $expense->public_notes = $recurring_expense->public_notes; $expense->transaction_reference = $recurring_expense->transaction_reference;