Handler/CustomerGroupHandler.php
public function checkGroup($groupCode)
    {
        /** @var SecurityContext $securityContext */
        $securityContext = $this->container->get('thelia.securityContext');

        return $securityContext->hasCustomerUser() && $this->getGroupCode() === $groupCode;
    }
public function checkGroup($groupCode)
    {
        /** @var SecurityContext $securityContext */
        $securityContext = $this->container->get('thelia.securityContext');

        return $securityContext->hasCustomerUser() && $this->getGroupCode() === $groupCode;
    }
public function checkGroup ( $ groupCode ) { /** @var SecurityContext $securityContext */ $ securityContext = $ this -> container -> get ( 'thelia.securityContext' ) ; return $ securityContext -> hasCustomerUser ( ) && $ this -> getGroupCode ( ) === $ groupCode ; }
Check if the current customer is in the asked group

@param string $groupCode Code for the group to check

@return boolean

@uses getGroupCode()
Check if the current customer is in the asked group