mirror of
https://github.com/firefly-iii/firefly-iii.git
synced 2025-10-22 12:11:19 +00:00
Code cleanup according to PHPStorm.
This commit is contained in:
@@ -13,7 +13,6 @@ use FireflyIII\Models\Tag;
|
||||
use FireflyIII\Models\Transaction;
|
||||
use FireflyIII\Models\TransactionJournal;
|
||||
use FireflyIII\Models\TransactionType;
|
||||
use FireflyIII\Support\CacheProperties;
|
||||
use Illuminate\Pagination\LengthAwarePaginator;
|
||||
use Illuminate\Support\Collection;
|
||||
use Log;
|
||||
@@ -45,14 +44,7 @@ class JournalRepository implements JournalRepositoryInterface
|
||||
*/
|
||||
public function first()
|
||||
{
|
||||
$cache = new CacheProperties;
|
||||
$cache->addProperty('user-first-journal');
|
||||
if ($cache->has()) {
|
||||
return $cache->get(); // @codeCoverageIgnore
|
||||
}
|
||||
|
||||
$entry = Auth::user()->transactionjournals()->orderBy('date', 'ASC')->first(['transaction_journals.*']);
|
||||
$cache->store($entry);
|
||||
|
||||
return $entry;
|
||||
}
|
||||
|
Reference in New Issue
Block a user