• Модуль: im
  • Путь к файлу: ~/bitrix/modules/im/lib/update/chatconfigconnectionsrestorer.php
  • Класс: BitrixImUpdateChatConfigConnectionsRestorer
  • Вызов: ChatConfigConnectionsRestorer::getDefaultGroupId
private function getDefaultGroupId(): int
{
	$defaultGroupId =
		OptionGroupTable::query()
			->addSelect('ID')
			->where('NAME', Configuration::DEFAULT_PRESET_NAME)
			->fetch()
	;

	if ($defaultGroupId)
	{
		Option::set('im', Configuration::DEFAULT_PRESET_SETTING_NAME, (int)$defaultGroupId['ID']);

		return (int)$defaultGroupId['ID'];
	}

	return $this->installDefaultPreset();
}