• Модуль: forum
  • Путь к файлу: ~/bitrix/modules/forum/lib/comments/feed.php
  • Класс: BitrixForumCommentsFeed
  • Вызов: Feed::add
public function add(array $params)
{
	if (!$this->canAdd())
		$this->errorCollection->addOne(new Error(Loc::getMessage("FORUM_CM_RIGHTS1"), self::ERROR_PERMISSION));
	else if ($this->checkTopic())
	{
		$comment = Comment::create($this);
		$comment->add($params);
		if ($comment->hasErrors())
			$this->errorCollection->add($comment->getErrors());
		else
			return $comment->getComment();
	}
	return false;
}