From d457ec131b43b1caffe9bf2f2ccd0dc6eced4e9a Mon Sep 17 00:00:00 2001 From: BobWez98 Date: Mon, 13 Jan 2025 14:33:16 +0000 Subject: [PATCH] Apply fixes from Duster --- src/Http/Controllers/FallbackController.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/Http/Controllers/FallbackController.php b/src/Http/Controllers/FallbackController.php index 023eb621..81da9ea3 100644 --- a/src/Http/Controllers/FallbackController.php +++ b/src/Http/Controllers/FallbackController.php @@ -43,7 +43,7 @@ public function __invoke(Request $request) BackedEnumCaseNotFoundException::class, ModelNotFoundException::class, RecordsNotFoundException::class, - ])->contains(fn($class) => $exception instanceof $class) || $request->expectsJson(); + ])->contains(fn ($class) => $exception instanceof $class) || $request->expectsJson(); }); if ($route && $response = $this->tryRoute($route['route'], $request)) { @@ -64,7 +64,7 @@ public function __invoke(Request $request) return $response; } - + Exceptions::shouldRenderJsonWhen(null); abort(404); }