mirror of
https://github.com/firefly-iii/firefly-iii.git
synced 2025-12-10 13:21:21 +00:00
Import statements and update configuration.
This commit is contained in:
@@ -34,6 +34,8 @@ use FireflyIII\User;
|
||||
use Illuminate\Foundation\Exceptions\Handler as ExceptionHandler;
|
||||
use Illuminate\Http\Request;
|
||||
use Symfony\Component\HttpFoundation\Response;
|
||||
use Override;
|
||||
use Throwable;
|
||||
|
||||
/**
|
||||
* Class GracefulNotFoundHandler
|
||||
@@ -45,12 +47,12 @@ class GracefulNotFoundHandler extends ExceptionHandler
|
||||
*
|
||||
* @param Request $request
|
||||
*
|
||||
* @throws \Throwable
|
||||
* @throws Throwable
|
||||
*
|
||||
* @SuppressWarnings("PHPMD.CyclomaticComplexity")
|
||||
*/
|
||||
#[\Override]
|
||||
public function render($request, \Throwable $e): Response
|
||||
#[Override]
|
||||
public function render($request, Throwable $e): Response
|
||||
{
|
||||
$route = $request->route();
|
||||
if (null === $route) {
|
||||
@@ -149,9 +151,9 @@ class GracefulNotFoundHandler extends ExceptionHandler
|
||||
}
|
||||
|
||||
/**
|
||||
* @throws \Throwable
|
||||
* @throws Throwable
|
||||
*/
|
||||
private function handleAccount(Request $request, \Throwable $exception): Response
|
||||
private function handleAccount(Request $request, Throwable $exception): Response
|
||||
{
|
||||
app('log')->debug('404 page is probably a deleted account. Redirect to overview of account types.');
|
||||
|
||||
@@ -184,9 +186,9 @@ class GracefulNotFoundHandler extends ExceptionHandler
|
||||
/**
|
||||
* @return Response
|
||||
*
|
||||
* @throws \Throwable
|
||||
* @throws Throwable
|
||||
*/
|
||||
private function handleGroup(Request $request, \Throwable $exception)
|
||||
private function handleGroup(Request $request, Throwable $exception)
|
||||
{
|
||||
app('log')->debug('404 page is probably a deleted group. Redirect to overview of group types.');
|
||||
|
||||
@@ -224,9 +226,9 @@ class GracefulNotFoundHandler extends ExceptionHandler
|
||||
/**
|
||||
* @return Response
|
||||
*
|
||||
* @throws \Throwable
|
||||
* @throws Throwable
|
||||
*/
|
||||
private function handleAttachment(Request $request, \Throwable $exception)
|
||||
private function handleAttachment(Request $request, Throwable $exception)
|
||||
{
|
||||
app('log')->debug('404 page is probably a deleted attachment. Redirect to parent object.');
|
||||
|
||||
|
||||
Reference in New Issue
Block a user