mirror of
https://github.com/laravel/laravel.git
synced 2025-02-20 11:53:14 +08:00
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.
|
||||
*/
|
||||
protected function redirectTo(Request $request): string|null
|
||||
protected function redirectTo(Request $request): ?string
|
||||
{
|
||||
return $request->expectsJson() ? null : route('login');
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user