Fix unauthorized redirect
MODIFY
app/Exceptions/Handler.php
app/Exceptions/Handler.php
@@ -60,6 +60,6 @@ class Handler extends ExceptionHandler
return response()->json(['error' => 'Unauthenticated.'], 401);
}
- return redirect()->guest(route('login_get'));
+ return redirect()->guest(route('login'));
}
}

Fix unauthorized redirect