Newscoop\Entity\Repository\CommentRepository::deleteCommenters PHP 메소드

deleteCommenters() 공개 메소드

Delete commenter comments
public deleteCommenters ( array $commenters )
$commenters array
    public function deleteCommenters(array $commenters)
    {
        $em = $this->getEntityManager();
        foreach ($commenters as $commenter) {
            $comments = $this->findByCommenter($commenter->getId());
            foreach ($comments as $comment) {
                $this->setCommentStatus($comment, 'deleted');
            }
        }
    }