• Модуль: calendar
  • Путь к файлу: ~/bitrix/modules/calendar/lib/sync/managers/pushwatchingmanager.php
  • Класс: BitrixCalendarSyncManagersPushWatchingManager
  • Вызов: PushWatchingManager::renewConnectionPush
private function renewConnectionPush(Push $pushChannel): void
{
	/** @var Connection $connection */
	$connection = $this->getConnectionMapper()->getById($pushChannel->getEntityId());
	if ($connection !== null && !$connection->isDeleted())
	{
		/** @var FactoryInterface $vendorFactory */
		$vendorFactory = $this->getFactoryByConnection($connection);
		/** @var PushManagerInterface $vendorPushManager */
		if ($vendorPushManager = $vendorFactory->getPushManager())
		{
			$result = $this->recreateConnectionPushChannel($vendorPushManager, $pushChannel, $connection);
			if ($result->isSuccess())
			{
				return;
			}
		}
	}

	$this->deleteChannel($pushChannel);
}