Files
einundzwanzig-portal/app/Http/Middleware/Authenticate.php
HolgerHatGarKeineNode 4534a57c02 lecturer cource events
2023-03-28 13:19:24 +02:00

18 lines
411 B
PHP

<?php
namespace App\Http\Middleware;
use Illuminate\Auth\Middleware\Authenticate as Middleware;
use Illuminate\Http\Request;
class Authenticate extends Middleware
{
/**
* Get the path the user should be redirected to when they are not authenticated.
*/
protected function redirectTo(Request $request): ?string
{
return $request->expectsJson() ? null : route('auth.ln');
}
}