mirror of
https://github.com/firefly-iii/firefly-iii.git
synced 2025-02-20 11:48:27 -06:00
Better transformer.
This commit is contained in:
parent
38b505d036
commit
2db32ce44f
@ -119,7 +119,7 @@ class TransactionGroupTransformer extends AbstractTransformer
|
||||
$type = $this->stringFromArray($transaction, 'transaction_type_type', TransactionType::WITHDRAWAL);
|
||||
$amount = app('steam')->positive((string)($row['amount'] ?? '0'));
|
||||
$foreignAmount = null;
|
||||
if (null !== $row['foreign_amount']) {
|
||||
if (null !== $row['foreign_amount'] && '' !== $row['foreign_amount'] && bccomp('0', $row['foreign_amount']) !== 0) {
|
||||
$foreignAmount = app('steam')->positive($row['foreign_amount']);
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user