Code cleanup and realign.

This commit is contained in:
James Cole
2018-08-06 19:14:30 +02:00
parent f7eef25fed
commit 5908c0ce8c
188 changed files with 1019 additions and 1031 deletions

View File

@@ -95,6 +95,7 @@ class PiggyBankEventTransformer extends TransformerAbstract
$pageSize = (int)app('preferences')->getForUser($journal->user, 'listPageSize', 50)->data;
// journals always use collector and limited using URL parameters.
/** @var JournalCollectorInterface $collector */
$collector = app(JournalCollectorInterface::class);
$collector->setUser($journal->user);
$collector->withOpposingAccount()->withCategoryInformation()->withCategoryInformation();
@@ -129,7 +130,8 @@ class PiggyBankEventTransformer extends TransformerAbstract
/** @var CurrencyRepositoryInterface $repository */
$repository = app(CurrencyRepositoryInterface::class);
$repository->setUser($account->user);
$currency = $repository->findNull($currencyId);
$currency = $repository->findNull($currencyId);
/** @noinspection NullPointerExceptionInspection */
$decimalPlaces = $currency->decimal_places;
}