mirror of
https://github.com/firefly-iii/firefly-iii.git
synced 2025-01-15 19:22:08 -06:00
Removed cache from typeIcon
This commit is contained in:
parent
9f16799453
commit
5978b1c421
@ -74,13 +74,6 @@ class Journal extends Twig_Extension
|
||||
return new Twig_SimpleFilter(
|
||||
'typeIcon', function (TransactionJournal $journal): string {
|
||||
|
||||
$cache = new CacheProperties();
|
||||
$cache->addProperty($journal->id);
|
||||
$cache->addProperty('typeIcon');
|
||||
if ($cache->has()) {
|
||||
return $cache->get(); // @codeCoverageIgnore
|
||||
}
|
||||
|
||||
switch (true) {
|
||||
case $journal->isWithdrawal():
|
||||
$txt = '<i class="fa fa-long-arrow-left fa-fw" title="' . trans('firefly.withdrawal') . '"></i>';
|
||||
@ -98,11 +91,8 @@ class Journal extends Twig_Extension
|
||||
$txt = '';
|
||||
break;
|
||||
}
|
||||
$cache->store($txt);
|
||||
|
||||
return $txt;
|
||||
|
||||
|
||||
}, ['is_safe' => ['html']]
|
||||
);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user