• Модуль: rest
  • Путь к файлу: ~/bitrix/modules/rest/lib/configuration/helper.php
  • Класс: BitrixRestConfigurationHelper
  • Вызов: Helper::getContextUser
public function getContextUser($postfix)
{
	$result = $this->prefixUserContext;

	$postfix = preg_replace('/[^a-zA-Z0-9_]/', '', $postfix);

	global $USER;
	if ($USER->IsAuthorized())
	{
		$user = $USER->GetID();
	}
	else
	{
		$user = 0;
	}

	$result .= $user.$postfix;
	return $result;
}