• Модуль: sender
  • Путь к файлу: ~/bitrix/modules/sender/lib/internals/postfiles.php
  • Класс: Bitrix\Sender\Internals\PostFiles
  • Вызов: PostFiles::getExisted
public function getExisted(array $files = null)
{
	$result = array();

	if (empty($files))
	{
		$files = $this->request->get($this->inputName);
	}
	if(!is_array($files))
	{
		return $result;
	}

	foreach($files as $index => $value)
	{
		if (!is_numeric($index) || !is_numeric($value))
		{
			continue;
		}

		$file = \CFile::getByID($value)->fetch();
		if (!$file || $file['MODULE_ID'] !== 'sender')
		{
			continue;
		}

		$result[] = (int) $value;
	}

	return $result;
}