Remove endorsement

@param \Haven\CmsBundle\Entity\CommentEndorsement $endorsement
499300
public function removeEndorsement(\Haven\CmsBundle\Entity\CommentEndorsement $endorsement) {
        $this->endorsements->removeElement($endorsement);
    }
194685
public function ClearCommentSelections($DiscussionID = '', $TransientKey = '') {
      $Session = Gdn::Session();
      if ($Session->ValidateTransientKey($TransientKey)) {
         $CheckedComments = Gdn::UserModel()->GetAttribute($Session->User->UserID, 'CheckedComments', array());
         unset($CheckedComments[$DiscussionID]);
         Gdn::UserModel()->SaveAttribute($Session->UserID, 'CheckedComments', $CheckedComments);
      }

      Redirect(GetIncomingValue('Target', '/discussions'));
   }
1116345
public function EditComment($CommentID = '', $DraftID = '') {
      if (is_numeric($CommentID) && $CommentID > 0) {
         $this->Form->SetModel($this->CommentModel);
         $this->Comment = $this->CommentModel->GetID($CommentID);
      } else {
         $this->Form->SetModel($this->DraftModel);
         $this->Comment = $this->DraftModel->GetID($DraftID);
      }
      
      $this->Form->RemoveFormValue('Format');
      $this->View = 'editcomment';
      $this->Comment($this->Comment->DiscussionID);
   }
203698
public function removeComment(\Innova\CollecticielBundle\Entity\CommentRead $comments)
    {
        $this->comments->removeElement($comments);
    }
865846
private function removeComments(HtmlDomParser $dom): HtmlDomParser
    {
        foreach ($dom->find('//comment()') as $commentWrapper) {
            $comment = $commentWrapper->getNode();
            $val = $comment->nodeValue;
            if (\strpos($val, '[') === false) {
                /** @noinspection UnusedFunctionResultInspection */
                $comment->parentNode->removeChild($comment);
            }
        }

        $dom->getDocument()->normalizeDocument();

        return $dom;
    }
722254
def deleteComment(self, repo_user, repo_name, comment_id):
        
        return self.api.makeRequest(
            ["repos", repo_user, repo_name,
             "pulls", "comments", str(comment_id)],
            method="DELETE")
1047351
public function process_endorsement($data) {
        global $DB;

        $data = (object)$data;

        $params = [
            'badgeid' => $this->get_new_parentid('badge'),
            'issuername' => $data->issuername,
            'issuerurl' => $data->issuerurl,
            'issueremail' => $data->issueremail,
            'claimid' => $data->claimid,
            'claimcomment' => $data->claimcomment,
            'dateissued' => $this->apply_date_offset($data->dateissued)
        ];
        $newid = $DB->insert_record('badge_endorsement', $params);
        $this->set_mapping('endorsement', $data->id, $newid);
    }
801458
public Comment removeComment(final long commentId) {
        Comment removedComment = null;

        if (comments != null) {
            for (int index = comments.size() - 1; index >= 0; --index) {
                Comment currentComment = comments.get(index);

                if (currentComment.getId() == commentId) {
                    removedComment = comments.remove(index);
                    break;
                }
            }
        }

        return removedComment;
    }
701079
public function removeAllAction()
    {
        $isPosted = $this->request->getPost('doRemoveAll');
        
        if (!$isPosted) {
            $this->response->redirect($this->request->getPost('redirect'));
        }

        $comments = new \Phpmvc\Comment\CommentsInSession();
        $comments->setDI($this->di);

        $comments->deleteAll();

        $this->response->redirect($this->request->getPost('redirect'));
    }
600404
private void removeCommentNodes(Document doc) {
        List<Node> toRemove = new ArrayList<>();
        NodeList children = doc.getChildNodes();
        for (int cn = 0; cn < children.getLength(); cn++) {
            Node child = children.item(cn);
            if (Node.COMMENT_NODE == child.getNodeType()) {
                toRemove.add(child);
            }
        }
        for (Node child : toRemove) {
            doc.removeChild(child);
        }
    }
1255204
public function removeComment(Comment $comment)
    {
        if ($this->comments->contains($comment)) {
            $this->comments->removeElement($comment);
            $comment->setTask(null);
        }

        return $this;
    }
1331963
public function removeProduct(\Sulu\Bundle\ProductBundle\Entity\Product $products)
    {
        $this->products->removeElement($products);
    }
549751
function deleteComment($commentId)
    {
        $params = array(1, $this->username, $this->password, $commentId);

        return $this->sendRequest('wp.deleteComment', $params);
    }
579560
public static function cleanComment($comment, $glueSeparator = ',', $uniqueValues = true)
    {
        if (!is_scalar($comment) && !is_array($comment)) {
            return '';
        }
        return trim(str_replace('*/', '*[:slash:]', is_scalar($comment) ? $comment : implode($glueSeparator, $uniqueValues ? array_unique($comment) : $comment)));
    }
1264018
public function destroy(UserPolicy $user, Comment $comment)
    {
        return $comment->user_id == user_id() && $comment->user_type == user_type();
    }
725668
public function removeCampaign(\CampaignChain\CoreBundle\Entity\Campaign $campaigns)
    {
        $this->campaigns->removeElement($campaigns);
    }
935456
public function removeProductSubscriptionsAsBuyer(\HarvestCloud\CoreBundle\Entity\ProductSubscription $productSubscription)
    {
        $this->productSubscriptionsAsBuyer->removeElement($productSubscription);
    }