Autoformat lol

This commit is contained in:
James Cole
2026-01-23 15:09:50 +01:00
parent ae1347c550
commit 8f15a32bd6
1071 changed files with 21111 additions and 21687 deletions
@@ -24,10 +24,10 @@ declare(strict_types=1);
namespace FireflyIII\Http\Controllers\Category;
use FireflyIII\Support\Facades\Preferences;
use FireflyIII\Http\Controllers\Controller;
use FireflyIII\Models\Category;
use FireflyIII\Repositories\Category\CategoryRepositoryInterface;
use FireflyIII\Support\Facades\Preferences;
use Illuminate\Contracts\View\Factory;
use Illuminate\Http\Request;
use Illuminate\Pagination\LengthAwarePaginator;
@@ -51,15 +51,13 @@ class IndexController extends Controller
{
parent::__construct();
$this->middleware(
function ($request, $next) {
app('view')->share('title', (string) trans('firefly.categories'));
app('view')->share('mainTitleIcon', 'fa-bookmark');
$this->repository = app(CategoryRepositoryInterface::class);
$this->middleware(function ($request, $next) {
app('view')->share('title', (string) trans('firefly.categories'));
app('view')->share('mainTitleIcon', 'fa-bookmark');
$this->repository = app(CategoryRepositoryInterface::class);
return $next($request);
}
);
return $next($request);
});
}
/**
@@ -78,11 +76,9 @@ class IndexController extends Controller
$total = $collection->count();
$collection = $collection->slice(($page - 1) * $pageSize, $pageSize);
$collection->each(
function (Category $category): void {
$category->lastActivity = $this->repository->lastUseDate($category, new Collection());
}
);
$collection->each(function (Category $category): void {
$category->lastActivity = $this->repository->lastUseDate($category, new Collection());
});
// paginate categories
$categories = new LengthAwarePaginator($collection, $total, $pageSize, $page);