compiled TS again
This commit is contained in:
parent
9269a08972
commit
8a6f437f4f
1 changed files with 16 additions and 2 deletions
|
@ -511,7 +511,7 @@ class Message {
|
|||
}
|
||||
func();
|
||||
}
|
||||
makeReaction(data, member) {
|
||||
reactionAdd(data, member) {
|
||||
for (const thing of this.reactions) {
|
||||
if (thing.emoji.name === data.name) {
|
||||
thing.count++;
|
||||
|
@ -529,7 +529,7 @@ class Message {
|
|||
});
|
||||
this.updateReactions();
|
||||
}
|
||||
removeReaction(data, id) {
|
||||
reactionRemove(data, id) {
|
||||
console.log("test");
|
||||
for (const i in this.reactions) {
|
||||
const thing = this.reactions[i];
|
||||
|
@ -549,6 +549,20 @@ class Message {
|
|||
}
|
||||
}
|
||||
}
|
||||
reactionRemoveAll() {
|
||||
this.reactions = [];
|
||||
this.updateReactions();
|
||||
}
|
||||
reactionRemoveEmoji(emoji) {
|
||||
for (const i in this.reactions) {
|
||||
const reaction = this.reactions[i];
|
||||
if ((reaction.emoji.id && reaction.emoji.id == emoji.id) || (!reaction.emoji.id && reaction.emoji.name == emoji.name)) {
|
||||
this.reactions.splice(i, 1);
|
||||
this.updateReactions();
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
buildhtml(premessage = undefined) {
|
||||
if (this.div) {
|
||||
console.error(`HTML for ${this.snowflake} already exists, aborting`);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue