Fix issue in liability credits.

This commit is contained in:
James Cole
2021-07-21 06:23:42 +02:00
parent 33d6584924
commit cb759e5c21
2 changed files with 2 additions and 1 deletions

View File

@@ -74,7 +74,7 @@ trait JournalServiceTrait
// and now try to find it, based on the type of transaction.
$message = 'Based on the fact that the transaction is a %s, the %s account should be in: %s. Direction is %s.';
Log::debug(sprintf($message, $transactionType, $direction, implode(', ', $expectedTypes[$transactionType]), $direction));
Log::debug(sprintf($message, $transactionType, $direction, implode(', ', $expectedTypes[$transactionType] ?? ['UNKNOWN']), $direction));
$result = $this->findAccountById($data, $expectedTypes[$transactionType]);
$result = $this->findAccountByName($result, $data, $expectedTypes[$transactionType]);