Use nullable typing (#6084)
This commit is contained in:
parent
f62d260c76
commit
de868f0fc7
|
@ -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');
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue