Skip to content

ProjectComment

Top Dog edited this page Apr 6, 2019 · 4 revisions

Properties

id

The id of the comment (String)

parentid

The parentid of the comment if the comment is a reply (String)

commenteeid

??? (???)

content

The content of the comment (String)

replyCount

The total amount of replies the comment has. (Number)

project

The project that the comment belongs to. (Project)

createdTimestamp

When the comment was created (String)

lastModifiedTimestamp

When the comment was last edited (String)

visible

Whether the comment is visible or not. (Boolean)

author

The author of the comment (CommentAuthor)

Methods

delete()

Delete the message. NOTE: Authorisation required. Returns Promise<>

ProjectComment.delete().then(() => {
  console.log("Making scratch a better place! Or not?");
});

report()

Report the message. NOTE: Authorisation required, I am not responsible for any negative impacts this has on your account. Returns Promise<>

ProjectComment.report().then(() => {
  console.log("Making scratch a better place!");
});

reply(content)

Reply to the message. NOTE: Authorisation required. Returns Promise<>

  • Content

The content of the reply (String)

ProjectComment.reply("Thank you!").then(() => {
  console.log("Thanked " + Comment.author.username + "!");
});
Clone this wiki locally