diff --git a/src/client/Client.js b/src/client/Client.js index 0fd8c18e6..c9e0e09e2 100644 --- a/src/client/Client.js +++ b/src/client/Client.js @@ -198,7 +198,7 @@ class Client extends EventEmitter { /** * Current status of the client's connection to Discord - * @type {?number} + * @type {?Status} * @readonly */ get status() { diff --git a/src/client/voice/VoiceConnection.js b/src/client/voice/VoiceConnection.js index ceab3cf14..e1297ee82 100644 --- a/src/client/voice/VoiceConnection.js +++ b/src/client/voice/VoiceConnection.js @@ -52,7 +52,7 @@ class VoiceConnection extends EventEmitter { /** * The current status of the voice connection - * @type {number} + * @type {VoiceStatus} */ this.status = Constants.VoiceStatus.AUTHENTICATING; diff --git a/src/structures/Message.js b/src/structures/Message.js index e87c33434..6a5fdd3dc 100644 --- a/src/structures/Message.js +++ b/src/structures/Message.js @@ -40,7 +40,7 @@ class Message { /** * The type of the message - * @type {string} + * @type {MessageType} */ this.type = Constants.MessageTypes[data.type]; diff --git a/src/util/Constants.js b/src/util/Constants.js index fdcc78d7b..64d9e5963 100644 --- a/src/util/Constants.js +++ b/src/util/Constants.js @@ -329,6 +329,18 @@ exports.WSEvents = { RELATIONSHIP_REMOVE: 'RELATIONSHIP_REMOVE', }; +/** + * The type of a message, e.g. `DEFAULT`. Here are the available types: + * - DEFAULT + * - RECIPIENT_ADD + * - RECIPIENT_REMOVE + * - CALL + * - CHANNEL_NAME_CHANGE + * - CHANNEL_ICON_CHANGE + * - PINS_ADD + * - GUILD_MEMBER_JOIN + * @typedef {string} MessageType + */ exports.MessageTypes = [ 'DEFAULT', 'RECIPIENT_ADD',