<?php

use External\ZNZBundle\Util\ZNZConfiguration;

function smarty_function_is_znz_b2b_shop($params, &$smarty)
{
    $result = \KupShop\KupShopBundle\Util\Compat\ServiceContainer::getService(ZNZConfiguration::class)->isB2BShop();

    if (!empty($params['assign'])) {
        $smarty->assign($params['assign'], $result);
    } else {
        return $result;
    }
}
