PHP Class App\Http\Middleware\LoginAs

Show file Open project: spatie-custom/blender

Public Methods

Method Description
handle ( $request, Closure $next )

Protected Methods

Method Description
canLoginAs ( ) : boolean
getUser ( string $identifier ) : Illuminate\Contracts\Auth\Authenticatable
loginAsAndRedirect ( string $identifier )

Method Details

canLoginAs() protected method

protected canLoginAs ( ) : boolean
return boolean

getUser() protected method

protected getUser ( string $identifier ) : Illuminate\Contracts\Auth\Authenticatable
$identifier string
return Illuminate\Contracts\Auth\Authenticatable

handle() public method

public handle ( $request, Closure $next )
$next Closure

loginAsAndRedirect() protected method

protected loginAsAndRedirect ( string $identifier )
$identifier string