class RedirectIfAuthenticated (View source)

Properties

static protected callable|null $redirectToCallback

The callback that should be used to generate the authentication redirect path.

Methods

Response
handle(Request $request, Closure $next, string ...$guards)

Handle an incoming request.

string|null
redirectTo(Request $request)

Get the path the user should be redirected to when they are authenticated.

string
defaultRedirectUri()

Get the default URI the user should be redirected to when they are authenticated.

static void
redirectUsing(callable $redirectToCallback)

Specify the callback that should be used to generate the redirect path.

Details

Response handle(Request $request, Closure $next, string ...$guards)

Handle an incoming request.

Parameters

Request $request
Closure $next
string ...$guards

Return Value

Response

protected string|null redirectTo(Request $request)

Get the path the user should be redirected to when they are authenticated.

Parameters

Request $request

Return Value

string|null

protected string defaultRedirectUri()

Get the default URI the user should be redirected to when they are authenticated.

Return Value

string

static void redirectUsing(callable $redirectToCallback)

Specify the callback that should be used to generate the redirect path.

Parameters

callable $redirectToCallback

Return Value

void