Skip to end of banner
Go to start of banner

editComment

Skip to end of metadata
Go to start of metadata

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

Version 1 Next »

Description

Edits a comment with the specified id and text. Optional, you can edit the security level for comment. Returns the comment representation after the edit.

Parameters

Return Type

/wiki/spaces/AA/pages/351830229

The comment representation with the following keys:

Examples

Example 1

string newComm = "This comment was edited.";
return editComment(11801, newComm);

Edits the comment with id 11801 with the specified text.

Example 2

string newComm = "This comment was edited.";
return editComment(11801, newComm, false);

Edits the comment with id 11801 with the specified text, the issue comment edited event will not be triggered.

Example 3

JComment jcomment = getCommentById(11801);
string oldComm = jcomment["text"];
string newComm = oldComm + "\nEditing the comment";
return editComment (11801, newComm, "Developers");

Edits a comment by adding new text to the old one and that can be viewed only by "Developers".

See also

  • No labels