diff --git a/app/Architecture/ExceptionHandler.php b/app/Architecture/ExceptionHandler.php index 5bf05d7..870de22 100644 --- a/app/Architecture/ExceptionHandler.php +++ b/app/Architecture/ExceptionHandler.php @@ -21,7 +21,7 @@ class ExceptionHandler extends Handler { $response = parent::render($request, $e); - if (!app()->environment(["local", "testing"]) && in_array($response->status(), [500, 503, 404, 403], true)) { + if (!app()->environment(["local", "testing"]) && in_array($response->status(), [500, 503, 419, 404, 403], true)) { return Inertia::render("Error", [ "status" => $response->status(), ]) @@ -29,12 +29,6 @@ class ExceptionHandler extends Handler ->setStatusCode($response->status()); } - if ($response->status() === 419) { - return back()->with([ - "message" => "The page expired, please try again.", - ]); - } - return $response; } }