mirror of
https://github.com/firefly-iii/firefly-iii.git
synced 2024-11-22 08:56:39 -06:00
Fix a rare null pointer
This commit is contained in:
parent
2e3e18d836
commit
2a38c9b4ef
@ -168,10 +168,11 @@ class BoxController extends Controller
|
||||
/** @var array $journal */
|
||||
foreach ($set as $journal) {
|
||||
$currencyId = (int)$journal['currency_id'];
|
||||
$amount = $journal['amount'] ?? '0';
|
||||
$incomes[$currencyId] = $incomes[$currencyId] ?? '0';
|
||||
$incomes[$currencyId] = bcadd($incomes[$currencyId], app('steam')->positive($journal['amount']));
|
||||
$incomes[$currencyId] = bcadd($incomes[$currencyId], app('steam')->positive($amount));
|
||||
$sums[$currencyId] = $sums[$currencyId] ?? '0';
|
||||
$sums[$currencyId] = bcadd($sums[$currencyId], app('steam')->positive($journal['amount']));
|
||||
$sums[$currencyId] = bcadd($sums[$currencyId], app('steam')->positive($amount));
|
||||
}
|
||||
|
||||
// collect expenses
|
||||
|
Loading…
Reference in New Issue
Block a user