Various code cleanup and phpstan suggestions

This commit is contained in:
James Cole
2022-11-02 06:25:37 +01:00
parent 74610a5d55
commit 8d8f81c27d
45 changed files with 147 additions and 27 deletions

View File

@@ -153,7 +153,7 @@ class AccountFactory
// try with type:
if (null === $result) {
$types = config(sprintf('firefly.accountTypeByIdentifier.%s', $accountTypeName)) ?? [];
if (!empty($types)) {
if (0 !== count($types)) {
$result = AccountType::whereIn('type', $types)->first();
}
}