mirror of
https://github.com/firefly-iii/firefly-iii.git
synced 2025-10-15 08:35:00 +00:00
Refactor phpstan errors.
This commit is contained in:
@@ -416,7 +416,7 @@ class BudgetRepository implements BudgetRepositoryInterface
|
||||
$autoBudget = $this->getAutoBudget($budget);
|
||||
|
||||
// grab default currency:
|
||||
$currency = app('amount')->getDefaultCurrencyByUser($this->user);
|
||||
$currency = app('amount')->getDefaultCurrencyByUserGroup($this->user->userGroup);
|
||||
|
||||
if (null === $autoBudget) {
|
||||
// at this point it's a blind assumption auto_budget_type is 1 or 2.
|
||||
@@ -847,7 +847,7 @@ class BudgetRepository implements BudgetRepositoryInterface
|
||||
$currency = $repos->findByCode((string)$data['currency_code']);
|
||||
}
|
||||
if (null === $currency) {
|
||||
$currency = app('amount')->getDefaultCurrencyByUser($this->user);
|
||||
$currency = app('amount')->getDefaultCurrencyByUserGroup($this->user->userGroup);
|
||||
}
|
||||
|
||||
$autoBudget = new AutoBudget();
|
||||
|
Reference in New Issue
Block a user