Use nullable typing (#6084)
This commit is contained in:
@@ -10,7 +10,7 @@ class Authenticate extends Middleware
|
|||||||
/**
|
/**
|
||||||
* Get the path the user should be redirected to when they are not authenticated.
|
* Get the path the user should be redirected to when they are not authenticated.
|
||||||
*/
|
*/
|
||||||
protected function redirectTo(Request $request): string|null
|
protected function redirectTo(Request $request): ?string
|
||||||
{
|
{
|
||||||
return $request->expectsJson() ? null : route('login');
|
return $request->expectsJson() ? null : route('login');
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user