Removed cache from typeIcon

This commit is contained in:
James Cole 2016-03-02 12:02:01 +01:00
parent 9f16799453
commit 5978b1c421

View File

@ -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']]
);
}