public function initService($serviceId, $serviceName, $actionName) { parent::initService($serviceId, $serviceName, $actionName); myPartnerUtils::addPartnerToCriteria(new VirusScanProfilePeer(), $this->getPartnerId(), $this->private_partner_data, $this->partnerGroup()); myPartnerUtils::addPartnerToCriteria(new flavorAssetPeer(), $this->getPartnerId(), $this->private_partner_data, $this->partnerGroup()); if (!VirusScanPlugin::isAllowedPartner($this->getPartnerId())) { throw new KalturaAPIException(KalturaErrors::SERVICE_FORBIDDEN, $this->serviceName . '->' . $this->actionName); } }
public function initService($serviceId, $serviceName, $actionName) { parent::initService($serviceId, $serviceName, $actionName); if ($this->getPartnerId() != Partner::ADMIN_CONSOLE_PARTNER_ID) { $this->applyPartnerFilterForClass('VirusScanProfile'); $this->applyPartnerFilterForClass('asset'); } if (!VirusScanPlugin::isAllowedPartner($this->getPartnerId())) { throw new KalturaAPIException(KalturaErrors::FEATURE_FORBIDDEN, VirusScanPlugin::PLUGIN_NAME); } }