public function getTokenGuard(Token $token, $guards)
    {
        $providers = GuardChecker::getGuardsProviders($guards);

        // use only guard associated to access token provider
        return $providers->has($token->provider) ? [$providers->get($token->provider)] : [];
    }
public function getTokenGuard(Token $token, $guards)
    {
        $providers = GuardChecker::getGuardsProviders($guards);

        // use only guard associated to access token provider
        return $providers->has($token->provider) ? [$providers->get($token->provider)] : [];
    }
public function getTokenGuard ( Token $ token , $ guards ) { $ providers = GuardChecker :: getGuardsProviders ( $ guards ) ; // use only guard associated to access token provider return $ providers -> has ( $ token -> provider ) ? [ $ providers -> get ( $ token -> provider ) ] : [ ] ; }
Get guard related with token.

@param Token $token
@param $guards
@return array
Get guard related with token .