mirror of
https://github.com/firefly-iii/firefly-iii.git
synced 2026-07-27 16:07:45 -07:00
🤖 Auto commit for release 'develop' on 2026-03-09
This commit is contained in:
@@ -129,7 +129,7 @@ class JournalRepository implements JournalRepositoryInterface, UserGroupInterfac
|
||||
*/
|
||||
public function firstNull(): ?TransactionJournal
|
||||
{
|
||||
/** @var TransactionJournal|null */
|
||||
/** @var null|TransactionJournal */
|
||||
return $this->user
|
||||
->transactionJournals()
|
||||
->orderBy('date', 'ASC')
|
||||
@@ -150,11 +150,13 @@ class JournalRepository implements JournalRepositoryInterface, UserGroupInterfac
|
||||
if (null === $transaction) {
|
||||
throw new FireflyException(sprintf('Your administration is broken. Transaction journal #%d has no destination transaction.', $journal->id));
|
||||
}
|
||||
/** @var Account|null $res */
|
||||
$res = $transaction->account;
|
||||
if(null === $res) {
|
||||
|
||||
/** @var null|Account $res */
|
||||
$res = $transaction->account;
|
||||
if (null === $res) {
|
||||
throw new FireflyException('Account is unexpectedly NULL.');
|
||||
}
|
||||
|
||||
return $res;
|
||||
}
|
||||
|
||||
@@ -180,7 +182,7 @@ class JournalRepository implements JournalRepositoryInterface, UserGroupInterfac
|
||||
|
||||
public function getLast(): ?TransactionJournal
|
||||
{
|
||||
/** @var TransactionJournal|null */
|
||||
/** @var null|TransactionJournal */
|
||||
return $this->user
|
||||
->transactionJournals()
|
||||
->orderBy('date', 'DESC')
|
||||
@@ -227,11 +229,12 @@ class JournalRepository implements JournalRepositoryInterface, UserGroupInterfac
|
||||
throw new FireflyException(sprintf('Your administration is broken. Transaction journal #%d has no source transaction.', $journal->id));
|
||||
}
|
||||
|
||||
/** @var Account|null $res */
|
||||
$res = $transaction->account;
|
||||
if(null === $res) {
|
||||
/** @var null|Account $res */
|
||||
$res = $transaction->account;
|
||||
if (null === $res) {
|
||||
throw new FireflyException('Account is unexpectedly NULL.');
|
||||
}
|
||||
|
||||
return $res;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user