public function createAction(Request $request, $postid)
    {
        $post = $this->getPost($postid);

        $entity = new Comment();
        $entity->setPost($post);
        $entity->setAuthor($this->getCurrentAuthor());
        $form   = $this->createForm(new CommentType(), $entity);
        $form->bind($request);

        if ($form->isValid()) {
            $em = $this->getDoctrine()->getManager();
            $em->persist($entity);
            $em->flush();

            $this->getSession()->getFlashBag()->set('success', 'The comment has been created successfully.');

            return $this->redirect($this->generateUrl('page_or_post', array('slug' => $post->getSlug())));
        }

        return array(
            'entity' => $entity,
            'post'   => $post,
            'form'   => $form->createView(),
        );
    }