public function create(array $data, MembershipInterface $author, ModelInterface $forum): PodiumResponse
    {
        /* @var $threadForm CategorisedFormInterface */
        $threadForm = $this->getForm();

        $threadForm->setAuthor($author);
        $threadForm->setForum($forum);

        if (!$threadForm->loadData($data)) {
            return PodiumResponse::error();
        }

        return $threadForm->create();
    }
public function create(array $data, MembershipInterface $author, ModelInterface $forum): PodiumResponse
    {
        /* @var $threadForm CategorisedFormInterface */
        $threadForm = $this->getForm();

        $threadForm->setAuthor($author);
        $threadForm->setForum($forum);

        if (!$threadForm->loadData($data)) {
            return PodiumResponse::error();
        }

        return $threadForm->create();
    }
public function create ( array $ data , MembershipInterface $ author , ModelInterface $ forum ) : PodiumResponse { /* @var $threadForm CategorisedFormInterface */ $ threadForm = $ this -> getForm ( ) ; $ threadForm -> setAuthor ( $ author ) ; $ threadForm -> setForum ( $ forum ) ; if ( ! $ threadForm -> loadData ( $ data ) ) { return PodiumResponse :: error ( ) ; } return $ threadForm -> create ( ) ; }
Creates thread.
@param array $data
@param MembershipInterface $author
@param ModelInterface $forum
@return PodiumResponse
Creates thread .