• Модуль: catalog
  • Путь к файлу: ~/bitrix/modules/catalog/lib/v2/Integration/Seo/Facebook/FacebookFacade.php
  • Класс: BitrixCatalogv2IntegrationSeoFacebookFacebookFacade
  • Вызов: FacebookFacade::getAuth
private function getAuth(): Result
{
	$result = new Result();

	if (!Loader::includeModule('seo'))
	{
		return $result->addError(new Error('The SEO module is not installed.'));
	}

	$service = Service::getInstance();

	if (!$service::getAuthAdapter($service::TYPE_FACEBOOK)->hasAuth())
	{
		return $result->addError(new Error('Facebook account with business suite is not authorized.'));
	}

	if (!$this->getCatalog())
	{
		return $result->addError(new Error('Facebook account is not authorized to use catalog features.'));
	}

	return $result;
}