mirror of
https://github.com/firefly-iii/firefly-iii.git
synced 2025-11-16 22:58:09 +00:00
Some code cleanup and fixes.
This commit is contained in:
@@ -96,7 +96,9 @@ class EloquentAccountRepository implements AccountRepositoryInterface
|
||||
public function findByName($name, \AccountType $type = null)
|
||||
{
|
||||
$type = is_null($type) ? \AccountType::where('description', 'Default account')->first() : $type;
|
||||
return \Auth::user()->accounts()->where('account_type_id',$type->id)->where('name', 'like', '%' . $name . '%')->first();
|
||||
|
||||
return \Auth::user()->accounts()->where('account_type_id', $type->id)->where('name', 'like', '%' . $name . '%')
|
||||
->first();
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user