mirror of
https://github.com/discordjs/discord.js.git
synced 2026-03-13 10:03:31 +01:00
Added semi-functional statuses
This commit is contained in:
@@ -24,9 +24,15 @@ var Channel = (function () {
|
||||
}, {
|
||||
key: "addMessage",
|
||||
value: function addMessage(data) {
|
||||
|
||||
if (this.messages.length > 1000) {
|
||||
this.messages.splice(0, 1);
|
||||
}
|
||||
|
||||
if (!this.getMessage("id", data.id)) {
|
||||
this.messages.push(data);
|
||||
}
|
||||
|
||||
return this.getMessage("id", data.id);
|
||||
}
|
||||
}, {
|
||||
|
||||
Reference in New Issue
Block a user