mirror of
https://github.com/firefly-iii/firefly-iii.git
synced 2025-02-25 18:45:27 -06:00
Code cleanup.
This commit is contained in:
@@ -43,12 +43,11 @@ class FixFrontpageAccounts extends Command
|
||||
|
||||
/**
|
||||
* Execute the console command.
|
||||
*
|
||||
* @return int
|
||||
*/
|
||||
public function handle(): int
|
||||
{
|
||||
$users = User::get();
|
||||
|
||||
/** @var User $user */
|
||||
foreach ($users as $user) {
|
||||
$preference = app('preferences')->getForUser($user, 'frontPageAccounts');
|
||||
@@ -61,12 +60,10 @@ class FixFrontpageAccounts extends Command
|
||||
return 0;
|
||||
}
|
||||
|
||||
/**
|
||||
* @param Preference $preference
|
||||
*/
|
||||
private function fixPreference(Preference $preference): void
|
||||
{
|
||||
$fixed = [];
|
||||
|
||||
/** @var AccountRepositoryInterface $repository */
|
||||
$repository = app(AccountRepositoryInterface::class);
|
||||
if (null === $preference->user) {
|
||||
|
||||
Reference in New Issue
Block a user