mirror of
https://github.com/firefly-iii/firefly-iii.git
synced 2025-10-12 15:35:15 +00:00
Various code cleanup.
This commit is contained in:
@@ -66,7 +66,7 @@ class BunqInformation implements InformationInterface
|
||||
}
|
||||
Log::debug('Now in getAccounts()');
|
||||
$sessionToken = $this->startSession();
|
||||
$userId = $this->getUserInformation($sessionToken);
|
||||
$userId = $this->getUserInformation($sessionToken);
|
||||
// get list of Bunq accounts:
|
||||
$accounts = $this->getMonetaryAccounts($sessionToken, $userId);
|
||||
$return = [];
|
||||
|
@@ -13,7 +13,6 @@ declare(strict_types=1);
|
||||
|
||||
namespace FireflyIII\Support;
|
||||
|
||||
use Amount as GlobalAmount;
|
||||
use Carbon\Carbon;
|
||||
use Crypt;
|
||||
use DB;
|
||||
@@ -51,7 +50,7 @@ class Steam
|
||||
$currencyId = intval($account->getMeta('currency_id'));
|
||||
// use system default currency:
|
||||
if ($currencyId === 0) {
|
||||
$currency = GlobalAmount::getDefaultCurrency();
|
||||
$currency = app('amount')->getDefaultCurrency();
|
||||
$currencyId = $currency->id;
|
||||
}
|
||||
// first part: get all balances in own currency:
|
||||
|
@@ -265,12 +265,12 @@ class AmountFormat extends Twig_Extension
|
||||
/**
|
||||
* @return Twig_SimpleFunction
|
||||
*/
|
||||
protected function journalTotalAmount(): Twig_SimpleFunction
|
||||
protected function journalAmount(): Twig_SimpleFunction
|
||||
{
|
||||
return new Twig_SimpleFunction(
|
||||
'journalTotalAmount', function (TransactionJournal $journal): string {
|
||||
'journalAmount', function (TransactionJournal $journal): string {
|
||||
|
||||
return app('amount')->journalTotalAmount($journal, true);
|
||||
return app('amount')->journalAmount($journal, true);
|
||||
}, ['is_safe' => ['html']]
|
||||
);
|
||||
}
|
||||
@@ -278,12 +278,12 @@ class AmountFormat extends Twig_Extension
|
||||
/**
|
||||
* @return Twig_SimpleFunction
|
||||
*/
|
||||
protected function journalAmount(): Twig_SimpleFunction
|
||||
protected function journalTotalAmount(): Twig_SimpleFunction
|
||||
{
|
||||
return new Twig_SimpleFunction(
|
||||
'journalAmount', function (TransactionJournal $journal): string {
|
||||
'journalTotalAmount', function (TransactionJournal $journal): string {
|
||||
|
||||
return app('amount')->journalAmount($journal, true);
|
||||
return app('amount')->journalTotalAmount($journal, true);
|
||||
}, ['is_safe' => ['html']]
|
||||
);
|
||||
}
|
||||
|
Reference in New Issue
Block a user