This commit is contained in:
root
2025-11-13 19:52:28 +03:00
parent 8aeeb05b7d
commit 807dec3b6c
4646 changed files with 163445 additions and 626017 deletions

View File

@@ -1,45 +0,0 @@
<?php
namespace Bitrix\Location\Common;
use Bitrix\Main\Loader;
/**
* Class RegionFinder
* @package Bitrix\Location\Common
*/
class RegionFinder
{
/**
* @return string
* @throws \Bitrix\Main\LoaderException
*/
public static function getCurrentRegion(): string
{
$result = null;
if (Loader::includeModule('bitrix24'))
{
$licensePrefix = \CBitrix24::getLicensePrefix();
if ($licensePrefix !== false)
{
$result = (string)$licensePrefix;
}
}
elseif (Loader::includeModule('intranet'))
{
$result = (string)\CIntranetUtils::getPortalZone();
}
elseif (defined('LANGUAGE_ID'))
{
$result = LANGUAGE_ID;
}
if (!$result)
{
$result = 'en';
}
return $result;
}
}