From 42505b78c15306491ac3a605f86a3e010bc80958 Mon Sep 17 00:00:00 2001 From: Gus Caplan Date: Mon, 3 Dec 2018 15:19:10 -0600 Subject: [PATCH] chore: add strict mode (#2974) --- .eslintrc.json | 1 + src/WebSocket.js | 2 ++ src/client/BaseClient.js | 2 ++ src/client/Client.js | 2 ++ src/client/WebhookClient.js | 2 ++ src/client/actions/Action.js | 2 ++ src/client/actions/ActionsManager.js | 2 ++ src/client/actions/ChannelCreate.js | 2 ++ src/client/actions/ChannelDelete.js | 2 ++ src/client/actions/ChannelUpdate.js | 2 ++ src/client/actions/GuildBanRemove.js | 2 ++ src/client/actions/GuildChannelsPositionUpdate.js | 2 ++ src/client/actions/GuildDelete.js | 2 ++ src/client/actions/GuildEmojiCreate.js | 2 ++ src/client/actions/GuildEmojiDelete.js | 2 ++ src/client/actions/GuildEmojiUpdate.js | 2 ++ src/client/actions/GuildEmojisUpdate.js | 2 ++ src/client/actions/GuildIntegrationsUpdate.js | 2 ++ src/client/actions/GuildMemberRemove.js | 2 ++ src/client/actions/GuildRoleCreate.js | 2 ++ src/client/actions/GuildRoleDelete.js | 2 ++ src/client/actions/GuildRoleUpdate.js | 2 ++ src/client/actions/GuildRolesPositionUpdate.js | 2 ++ src/client/actions/GuildUpdate.js | 2 ++ src/client/actions/MessageCreate.js | 2 ++ src/client/actions/MessageDelete.js | 2 ++ src/client/actions/MessageDeleteBulk.js | 2 ++ src/client/actions/MessageReactionAdd.js | 2 ++ src/client/actions/MessageReactionRemove.js | 2 ++ src/client/actions/MessageReactionRemoveAll.js | 2 ++ src/client/actions/MessageUpdate.js | 2 ++ src/client/actions/PresenceUpdate.js | 2 ++ src/client/actions/UserUpdate.js | 2 ++ src/client/actions/VoiceStateUpdate.js | 2 ++ src/client/actions/WebhooksUpdate.js | 2 ++ src/client/voice/ClientVoiceManager.js | 2 ++ src/client/voice/VoiceBroadcast.js | 2 ++ src/client/voice/VoiceConnection.js | 2 ++ src/client/voice/dispatcher/BroadcastDispatcher.js | 2 ++ src/client/voice/dispatcher/StreamDispatcher.js | 2 ++ src/client/voice/networking/VoiceUDPClient.js | 2 ++ src/client/voice/networking/VoiceWebSocket.js | 2 ++ src/client/voice/player/AudioPlayer.js | 2 ++ src/client/voice/player/BasePlayer.js | 2 ++ src/client/voice/player/BroadcastAudioPlayer.js | 2 ++ src/client/voice/receiver/PacketHandler.js | 2 ++ src/client/voice/receiver/Receiver.js | 2 ++ src/client/voice/util/DispatcherSet.js | 2 ++ src/client/voice/util/PlayInterface.js | 2 ++ src/client/voice/util/Secretbox.js | 2 ++ src/client/voice/util/Silence.js | 2 ++ src/client/voice/util/VolumeInterface.js | 2 ++ src/client/websocket/WebSocketManager.js | 2 ++ src/client/websocket/WebSocketShard.js | 2 ++ src/client/websocket/handlers/CHANNEL_CREATE.js | 2 ++ src/client/websocket/handlers/CHANNEL_DELETE.js | 2 ++ src/client/websocket/handlers/CHANNEL_PINS_UPDATE.js | 2 ++ src/client/websocket/handlers/CHANNEL_UPDATE.js | 2 ++ src/client/websocket/handlers/GUILD_BAN_ADD.js | 2 ++ src/client/websocket/handlers/GUILD_BAN_REMOVE.js | 2 ++ src/client/websocket/handlers/GUILD_CREATE.js | 2 ++ src/client/websocket/handlers/GUILD_DELETE.js | 2 ++ src/client/websocket/handlers/GUILD_EMOJIS_UPDATE.js | 2 ++ src/client/websocket/handlers/GUILD_INTEGRATIONS_UPDATE.js | 2 ++ src/client/websocket/handlers/GUILD_MEMBERS_CHUNK.js | 2 ++ src/client/websocket/handlers/GUILD_MEMBER_ADD.js | 2 ++ src/client/websocket/handlers/GUILD_MEMBER_REMOVE.js | 2 ++ src/client/websocket/handlers/GUILD_MEMBER_UPDATE.js | 2 ++ src/client/websocket/handlers/GUILD_ROLE_CREATE.js | 2 ++ src/client/websocket/handlers/GUILD_ROLE_DELETE.js | 2 ++ src/client/websocket/handlers/GUILD_ROLE_UPDATE.js | 2 ++ src/client/websocket/handlers/GUILD_SYNC.js | 2 ++ src/client/websocket/handlers/GUILD_UPDATE.js | 2 ++ src/client/websocket/handlers/MESSAGE_CREATE.js | 2 ++ src/client/websocket/handlers/MESSAGE_DELETE.js | 2 ++ src/client/websocket/handlers/MESSAGE_DELETE_BULK.js | 2 ++ src/client/websocket/handlers/MESSAGE_REACTION_ADD.js | 2 ++ src/client/websocket/handlers/MESSAGE_REACTION_REMOVE.js | 2 ++ src/client/websocket/handlers/MESSAGE_REACTION_REMOVE_ALL.js | 2 ++ src/client/websocket/handlers/MESSAGE_UPDATE.js | 2 ++ src/client/websocket/handlers/PRESENCE_UPDATE.js | 2 ++ src/client/websocket/handlers/READY.js | 2 ++ src/client/websocket/handlers/RESUMED.js | 2 ++ src/client/websocket/handlers/TYPING_START.js | 2 ++ src/client/websocket/handlers/USER_UPDATE.js | 2 ++ src/client/websocket/handlers/VOICE_SERVER_UPDATE.js | 2 ++ src/client/websocket/handlers/VOICE_STATE_UPDATE.js | 2 ++ src/client/websocket/handlers/WEBHOOKS_UPDATE.js | 2 ++ src/client/websocket/handlers/index.js | 2 ++ src/errors/DJSError.js | 2 ++ src/errors/Messages.js | 2 ++ src/errors/index.js | 2 ++ src/index.js | 2 ++ src/rest/APIRequest.js | 2 ++ src/rest/APIRouter.js | 2 ++ src/rest/DiscordAPIError.js | 2 ++ src/rest/HTTPError.js | 2 ++ src/rest/RESTManager.js | 2 ++ src/rest/RequestHandler.js | 2 ++ src/sharding/Shard.js | 2 ++ src/sharding/ShardClientUtil.js | 2 ++ src/sharding/ShardingManager.js | 2 ++ src/stores/ChannelStore.js | 2 ++ src/stores/DataStore.js | 2 ++ src/stores/GuildChannelStore.js | 2 ++ src/stores/GuildEmojiRoleStore.js | 2 ++ src/stores/GuildEmojiStore.js | 2 ++ src/stores/GuildMemberRoleStore.js | 2 ++ src/stores/GuildMemberStore.js | 2 ++ src/stores/GuildStore.js | 2 ++ src/stores/MessageStore.js | 2 ++ src/stores/PresenceStore.js | 2 ++ src/stores/ReactionStore.js | 2 ++ src/stores/ReactionUserStore.js | 2 ++ src/stores/RoleStore.js | 2 ++ src/stores/UserStore.js | 2 ++ src/stores/VoiceStateStore.js | 2 ++ src/structures/APIMessage.js | 2 ++ src/structures/Base.js | 2 ++ src/structures/CategoryChannel.js | 2 ++ src/structures/Channel.js | 2 ++ src/structures/ClientApplication.js | 2 ++ src/structures/ClientPresence.js | 2 ++ src/structures/ClientUser.js | 2 ++ src/structures/DMChannel.js | 2 ++ src/structures/Emoji.js | 2 ++ src/structures/GroupDMChannel.js | 2 ++ src/structures/Guild.js | 2 ++ src/structures/GuildAuditLogs.js | 2 ++ src/structures/GuildChannel.js | 2 ++ src/structures/GuildEmoji.js | 2 ++ src/structures/GuildMember.js | 2 ++ src/structures/Integration.js | 2 ++ src/structures/Invite.js | 2 ++ src/structures/Message.js | 2 ++ src/structures/MessageAttachment.js | 2 ++ src/structures/MessageCollector.js | 2 ++ src/structures/MessageEmbed.js | 2 ++ src/structures/MessageMentions.js | 2 ++ src/structures/MessageReaction.js | 2 ++ src/structures/PermissionOverwrites.js | 2 ++ src/structures/Presence.js | 2 ++ src/structures/ReactionCollector.js | 2 ++ src/structures/ReactionEmoji.js | 2 ++ src/structures/Role.js | 2 ++ src/structures/TextChannel.js | 2 ++ src/structures/User.js | 2 ++ src/structures/VoiceChannel.js | 2 ++ src/structures/VoiceRegion.js | 2 ++ src/structures/VoiceState.js | 2 ++ src/structures/Webhook.js | 2 ++ src/structures/interfaces/Collector.js | 2 ++ src/structures/interfaces/TextBasedChannel.js | 2 ++ src/util/ActivityFlags.js | 2 ++ src/util/BitField.js | 2 ++ src/util/Collection.js | 2 ++ src/util/Constants.js | 2 ++ src/util/DataResolver.js | 2 ++ src/util/Permissions.js | 2 ++ src/util/Snowflake.js | 2 ++ src/util/Speaking.js | 2 ++ src/util/Structures.js | 2 ++ src/util/Util.js | 2 ++ webpack.config.js | 2 ++ 164 files changed, 327 insertions(+) diff --git a/.eslintrc.json b/.eslintrc.json index 9b7c229b6..a4f08d689 100644 --- a/.eslintrc.json +++ b/.eslintrc.json @@ -11,6 +11,7 @@ { "files": ["*.browser.js"], "env": { "browser": true } } ], "rules": { + "strict": ["error", "global"], "no-await-in-loop": "warn", "no-compare-neg-zero": "error", "no-extra-parens": ["warn", "all", { diff --git a/src/WebSocket.js b/src/WebSocket.js index c6f4209fb..2a303cc46 100644 --- a/src/WebSocket.js +++ b/src/WebSocket.js @@ -1,3 +1,5 @@ +'use strict'; + const { browser } = require('./util/Constants'); const querystring = require('querystring'); try { diff --git a/src/client/BaseClient.js b/src/client/BaseClient.js index c9fce5908..68621360e 100644 --- a/src/client/BaseClient.js +++ b/src/client/BaseClient.js @@ -1,3 +1,5 @@ +'use strict'; + require('setimmediate'); const EventEmitter = require('events'); const RESTManager = require('../rest/RESTManager'); diff --git a/src/client/Client.js b/src/client/Client.js index 5d5deddf6..1bc8232b8 100644 --- a/src/client/Client.js +++ b/src/client/Client.js @@ -1,3 +1,5 @@ +'use strict'; + const BaseClient = require('./BaseClient'); const Permissions = require('../util/Permissions'); const ClientVoiceManager = require('./voice/ClientVoiceManager'); diff --git a/src/client/WebhookClient.js b/src/client/WebhookClient.js index 0a848d808..94e17a71d 100644 --- a/src/client/WebhookClient.js +++ b/src/client/WebhookClient.js @@ -1,3 +1,5 @@ +'use strict'; + const Webhook = require('../structures/Webhook'); const BaseClient = require('./BaseClient'); diff --git a/src/client/actions/Action.js b/src/client/actions/Action.js index 8fdadc92b..791eaa00c 100644 --- a/src/client/actions/Action.js +++ b/src/client/actions/Action.js @@ -1,3 +1,5 @@ +'use strict'; + /* ABOUT ACTIONS diff --git a/src/client/actions/ActionsManager.js b/src/client/actions/ActionsManager.js index f349b9bcd..268e4371b 100644 --- a/src/client/actions/ActionsManager.js +++ b/src/client/actions/ActionsManager.js @@ -1,3 +1,5 @@ +'use strict'; + class ActionsManager { constructor(client) { this.client = client; diff --git a/src/client/actions/ChannelCreate.js b/src/client/actions/ChannelCreate.js index 57b4e6dfd..4a9d17d45 100644 --- a/src/client/actions/ChannelCreate.js +++ b/src/client/actions/ChannelCreate.js @@ -1,3 +1,5 @@ +'use strict'; + const Action = require('./Action'); const { Events } = require('../../util/Constants'); diff --git a/src/client/actions/ChannelDelete.js b/src/client/actions/ChannelDelete.js index 7f182e60c..b9909f8ba 100644 --- a/src/client/actions/ChannelDelete.js +++ b/src/client/actions/ChannelDelete.js @@ -1,3 +1,5 @@ +'use strict'; + const Action = require('./Action'); const { Events } = require('../../util/Constants'); diff --git a/src/client/actions/ChannelUpdate.js b/src/client/actions/ChannelUpdate.js index ac2d4f69a..b610ea7ca 100644 --- a/src/client/actions/ChannelUpdate.js +++ b/src/client/actions/ChannelUpdate.js @@ -1,3 +1,5 @@ +'use strict'; + const Action = require('./Action'); class ChannelUpdateAction extends Action { diff --git a/src/client/actions/GuildBanRemove.js b/src/client/actions/GuildBanRemove.js index 7d19c75ba..62779137f 100644 --- a/src/client/actions/GuildBanRemove.js +++ b/src/client/actions/GuildBanRemove.js @@ -1,3 +1,5 @@ +'use strict'; + const Action = require('./Action'); const { Events } = require('../../util/Constants'); diff --git a/src/client/actions/GuildChannelsPositionUpdate.js b/src/client/actions/GuildChannelsPositionUpdate.js index 863d7dc51..b21115947 100644 --- a/src/client/actions/GuildChannelsPositionUpdate.js +++ b/src/client/actions/GuildChannelsPositionUpdate.js @@ -1,3 +1,5 @@ +'use strict'; + const Action = require('./Action'); class GuildChannelsPositionUpdate extends Action { diff --git a/src/client/actions/GuildDelete.js b/src/client/actions/GuildDelete.js index 27ea1b001..7c61ebacd 100644 --- a/src/client/actions/GuildDelete.js +++ b/src/client/actions/GuildDelete.js @@ -1,3 +1,5 @@ +'use strict'; + const Action = require('./Action'); const { Events } = require('../../util/Constants'); diff --git a/src/client/actions/GuildEmojiCreate.js b/src/client/actions/GuildEmojiCreate.js index 121e89ab9..379c62e0e 100644 --- a/src/client/actions/GuildEmojiCreate.js +++ b/src/client/actions/GuildEmojiCreate.js @@ -1,3 +1,5 @@ +'use strict'; + const Action = require('./Action'); const { Events } = require('../../util/Constants'); diff --git a/src/client/actions/GuildEmojiDelete.js b/src/client/actions/GuildEmojiDelete.js index 7b94ff41c..d5c973afa 100644 --- a/src/client/actions/GuildEmojiDelete.js +++ b/src/client/actions/GuildEmojiDelete.js @@ -1,3 +1,5 @@ +'use strict'; + const Action = require('./Action'); const { Events } = require('../../util/Constants'); diff --git a/src/client/actions/GuildEmojiUpdate.js b/src/client/actions/GuildEmojiUpdate.js index 34e235a0a..9fa59c96a 100644 --- a/src/client/actions/GuildEmojiUpdate.js +++ b/src/client/actions/GuildEmojiUpdate.js @@ -1,3 +1,5 @@ +'use strict'; + const Action = require('./Action'); const { Events } = require('../../util/Constants'); diff --git a/src/client/actions/GuildEmojisUpdate.js b/src/client/actions/GuildEmojisUpdate.js index aaa898477..d6902d535 100644 --- a/src/client/actions/GuildEmojisUpdate.js +++ b/src/client/actions/GuildEmojisUpdate.js @@ -1,3 +1,5 @@ +'use strict'; + const Action = require('./Action'); class GuildEmojisUpdateAction extends Action { diff --git a/src/client/actions/GuildIntegrationsUpdate.js b/src/client/actions/GuildIntegrationsUpdate.js index 8bb6eabf3..a8e910774 100644 --- a/src/client/actions/GuildIntegrationsUpdate.js +++ b/src/client/actions/GuildIntegrationsUpdate.js @@ -1,3 +1,5 @@ +'use strict'; + const Action = require('./Action'); const { Events } = require('../../util/Constants'); diff --git a/src/client/actions/GuildMemberRemove.js b/src/client/actions/GuildMemberRemove.js index 62373e486..6a4ae397e 100644 --- a/src/client/actions/GuildMemberRemove.js +++ b/src/client/actions/GuildMemberRemove.js @@ -1,3 +1,5 @@ +'use strict'; + const Action = require('./Action'); const { Events, Status } = require('../../util/Constants'); diff --git a/src/client/actions/GuildRoleCreate.js b/src/client/actions/GuildRoleCreate.js index e4657213b..36111f064 100644 --- a/src/client/actions/GuildRoleCreate.js +++ b/src/client/actions/GuildRoleCreate.js @@ -1,3 +1,5 @@ +'use strict'; + const Action = require('./Action'); const { Events } = require('../../util/Constants'); diff --git a/src/client/actions/GuildRoleDelete.js b/src/client/actions/GuildRoleDelete.js index 0cecc8efe..31b13b812 100644 --- a/src/client/actions/GuildRoleDelete.js +++ b/src/client/actions/GuildRoleDelete.js @@ -1,3 +1,5 @@ +'use strict'; + const Action = require('./Action'); const { Events } = require('../../util/Constants'); diff --git a/src/client/actions/GuildRoleUpdate.js b/src/client/actions/GuildRoleUpdate.js index c2e082c70..bf61c7878 100644 --- a/src/client/actions/GuildRoleUpdate.js +++ b/src/client/actions/GuildRoleUpdate.js @@ -1,3 +1,5 @@ +'use strict'; + const Action = require('./Action'); const { Events } = require('../../util/Constants'); diff --git a/src/client/actions/GuildRolesPositionUpdate.js b/src/client/actions/GuildRolesPositionUpdate.js index af29702ad..f09f11436 100644 --- a/src/client/actions/GuildRolesPositionUpdate.js +++ b/src/client/actions/GuildRolesPositionUpdate.js @@ -1,3 +1,5 @@ +'use strict'; + const Action = require('./Action'); class GuildRolesPositionUpdate extends Action { diff --git a/src/client/actions/GuildUpdate.js b/src/client/actions/GuildUpdate.js index ac592d277..6d7cf9b4e 100644 --- a/src/client/actions/GuildUpdate.js +++ b/src/client/actions/GuildUpdate.js @@ -1,3 +1,5 @@ +'use strict'; + const Action = require('./Action'); const { Events } = require('../../util/Constants'); diff --git a/src/client/actions/MessageCreate.js b/src/client/actions/MessageCreate.js index e34eabc2b..d4ef64001 100644 --- a/src/client/actions/MessageCreate.js +++ b/src/client/actions/MessageCreate.js @@ -1,3 +1,5 @@ +'use strict'; + const Action = require('./Action'); const { Events } = require('../../util/Constants'); diff --git a/src/client/actions/MessageDelete.js b/src/client/actions/MessageDelete.js index cbe555e86..d66d10a28 100644 --- a/src/client/actions/MessageDelete.js +++ b/src/client/actions/MessageDelete.js @@ -1,3 +1,5 @@ +'use strict'; + const Action = require('./Action'); const { Events } = require('../../util/Constants'); diff --git a/src/client/actions/MessageDeleteBulk.js b/src/client/actions/MessageDeleteBulk.js index ac8d9b399..53f4ba051 100644 --- a/src/client/actions/MessageDeleteBulk.js +++ b/src/client/actions/MessageDeleteBulk.js @@ -1,3 +1,5 @@ +'use strict'; + const Action = require('./Action'); const Collection = require('../../util/Collection'); const { Events } = require('../../util/Constants'); diff --git a/src/client/actions/MessageReactionAdd.js b/src/client/actions/MessageReactionAdd.js index 06b146df6..a800c3c7a 100644 --- a/src/client/actions/MessageReactionAdd.js +++ b/src/client/actions/MessageReactionAdd.js @@ -1,3 +1,5 @@ +'use strict'; + const Action = require('./Action'); /* diff --git a/src/client/actions/MessageReactionRemove.js b/src/client/actions/MessageReactionRemove.js index af76c4fd9..7ab5be289 100644 --- a/src/client/actions/MessageReactionRemove.js +++ b/src/client/actions/MessageReactionRemove.js @@ -1,3 +1,5 @@ +'use strict'; + const Action = require('./Action'); const { Events } = require('../../util/Constants'); diff --git a/src/client/actions/MessageReactionRemoveAll.js b/src/client/actions/MessageReactionRemoveAll.js index ac03c6e83..f32730977 100644 --- a/src/client/actions/MessageReactionRemoveAll.js +++ b/src/client/actions/MessageReactionRemoveAll.js @@ -1,3 +1,5 @@ +'use strict'; + const Action = require('./Action'); const { Events } = require('../../util/Constants'); diff --git a/src/client/actions/MessageUpdate.js b/src/client/actions/MessageUpdate.js index 4fbdce4e4..be26b2692 100644 --- a/src/client/actions/MessageUpdate.js +++ b/src/client/actions/MessageUpdate.js @@ -1,3 +1,5 @@ +'use strict'; + const Action = require('./Action'); class MessageUpdateAction extends Action { diff --git a/src/client/actions/PresenceUpdate.js b/src/client/actions/PresenceUpdate.js index 538e0e8af..649bf6ce0 100644 --- a/src/client/actions/PresenceUpdate.js +++ b/src/client/actions/PresenceUpdate.js @@ -1,3 +1,5 @@ +'use strict'; + const Action = require('./Action'); const { Events } = require('../../util/Constants'); diff --git a/src/client/actions/UserUpdate.js b/src/client/actions/UserUpdate.js index 3ff407901..a762511f4 100644 --- a/src/client/actions/UserUpdate.js +++ b/src/client/actions/UserUpdate.js @@ -1,3 +1,5 @@ +'use strict'; + const Action = require('./Action'); const { Events } = require('../../util/Constants'); diff --git a/src/client/actions/VoiceStateUpdate.js b/src/client/actions/VoiceStateUpdate.js index 80e120cb2..e4efa1292 100644 --- a/src/client/actions/VoiceStateUpdate.js +++ b/src/client/actions/VoiceStateUpdate.js @@ -1,3 +1,5 @@ +'use strict'; + const Action = require('./Action'); const { Events } = require('../../util/Constants'); const VoiceState = require('../../structures/VoiceState'); diff --git a/src/client/actions/WebhooksUpdate.js b/src/client/actions/WebhooksUpdate.js index 08ec838f1..69e28aecb 100644 --- a/src/client/actions/WebhooksUpdate.js +++ b/src/client/actions/WebhooksUpdate.js @@ -1,3 +1,5 @@ +'use strict'; + const Action = require('./Action'); const { Events } = require('../../util/Constants'); diff --git a/src/client/voice/ClientVoiceManager.js b/src/client/voice/ClientVoiceManager.js index d55a809f2..a9081efd5 100644 --- a/src/client/voice/ClientVoiceManager.js +++ b/src/client/voice/ClientVoiceManager.js @@ -1,3 +1,5 @@ +'use strict'; + const Collection = require('../../util/Collection'); const { VoiceStatus } = require('../../util/Constants'); const VoiceConnection = require('./VoiceConnection'); diff --git a/src/client/voice/VoiceBroadcast.js b/src/client/voice/VoiceBroadcast.js index 1bc4e2827..602f59205 100644 --- a/src/client/voice/VoiceBroadcast.js +++ b/src/client/voice/VoiceBroadcast.js @@ -1,3 +1,5 @@ +'use strict'; + const EventEmitter = require('events'); const BroadcastAudioPlayer = require('./player/BroadcastAudioPlayer'); const DispatcherSet = require('./util/DispatcherSet'); diff --git a/src/client/voice/VoiceConnection.js b/src/client/voice/VoiceConnection.js index 6a4d4cdaa..078781b53 100644 --- a/src/client/voice/VoiceConnection.js +++ b/src/client/voice/VoiceConnection.js @@ -1,3 +1,5 @@ +'use strict'; + const VoiceWebSocket = require('./networking/VoiceWebSocket'); const VoiceUDP = require('./networking/VoiceUDPClient'); const Util = require('../../util/Util'); diff --git a/src/client/voice/dispatcher/BroadcastDispatcher.js b/src/client/voice/dispatcher/BroadcastDispatcher.js index 90cff6a40..e5c7650cf 100644 --- a/src/client/voice/dispatcher/BroadcastDispatcher.js +++ b/src/client/voice/dispatcher/BroadcastDispatcher.js @@ -1,3 +1,5 @@ +'use strict'; + const StreamDispatcher = require('./StreamDispatcher'); /** diff --git a/src/client/voice/dispatcher/StreamDispatcher.js b/src/client/voice/dispatcher/StreamDispatcher.js index 7bb0ef1b0..93c6df81f 100644 --- a/src/client/voice/dispatcher/StreamDispatcher.js +++ b/src/client/voice/dispatcher/StreamDispatcher.js @@ -1,3 +1,5 @@ +'use strict'; + const VolumeInterface = require('../util/VolumeInterface'); const { Writable } = require('stream'); diff --git a/src/client/voice/networking/VoiceUDPClient.js b/src/client/voice/networking/VoiceUDPClient.js index fe34cab33..c1dd9e3d0 100644 --- a/src/client/voice/networking/VoiceUDPClient.js +++ b/src/client/voice/networking/VoiceUDPClient.js @@ -1,3 +1,5 @@ +'use strict'; + const udp = require('dgram'); const { VoiceOPCodes } = require('../../../util/Constants'); const EventEmitter = require('events'); diff --git a/src/client/voice/networking/VoiceWebSocket.js b/src/client/voice/networking/VoiceWebSocket.js index bd03ea54a..d556145b4 100644 --- a/src/client/voice/networking/VoiceWebSocket.js +++ b/src/client/voice/networking/VoiceWebSocket.js @@ -1,3 +1,5 @@ +'use strict'; + const { OPCodes, VoiceOPCodes } = require('../../../util/Constants'); const EventEmitter = require('events'); const { Error } = require('../../../errors'); diff --git a/src/client/voice/player/AudioPlayer.js b/src/client/voice/player/AudioPlayer.js index e3381f5cc..3ce94d815 100644 --- a/src/client/voice/player/AudioPlayer.js +++ b/src/client/voice/player/AudioPlayer.js @@ -1,3 +1,5 @@ +'use strict'; + const BasePlayer = require('./BasePlayer'); /** diff --git a/src/client/voice/player/BasePlayer.js b/src/client/voice/player/BasePlayer.js index e19984dff..c9c6cf0d1 100644 --- a/src/client/voice/player/BasePlayer.js +++ b/src/client/voice/player/BasePlayer.js @@ -1,3 +1,5 @@ +'use strict'; + const EventEmitter = require('events').EventEmitter; const { Readable: ReadableStream } = require('stream'); const prism = require('prism-media'); diff --git a/src/client/voice/player/BroadcastAudioPlayer.js b/src/client/voice/player/BroadcastAudioPlayer.js index 052c9ea0b..c1cab9f41 100644 --- a/src/client/voice/player/BroadcastAudioPlayer.js +++ b/src/client/voice/player/BroadcastAudioPlayer.js @@ -1,3 +1,5 @@ +'use strict'; + const BroadcastDispatcher = require('../dispatcher/BroadcastDispatcher'); const BasePlayer = require('./BasePlayer'); diff --git a/src/client/voice/receiver/PacketHandler.js b/src/client/voice/receiver/PacketHandler.js index 1ea702c1f..7189f1126 100644 --- a/src/client/voice/receiver/PacketHandler.js +++ b/src/client/voice/receiver/PacketHandler.js @@ -1,3 +1,5 @@ +'use strict'; + const secretbox = require('../util/Secretbox'); const EventEmitter = require('events'); diff --git a/src/client/voice/receiver/Receiver.js b/src/client/voice/receiver/Receiver.js index 1174f70bf..605d99271 100644 --- a/src/client/voice/receiver/Receiver.js +++ b/src/client/voice/receiver/Receiver.js @@ -1,3 +1,5 @@ +'use strict'; + const EventEmitter = require('events'); const prism = require('prism-media'); const PacketHandler = require('./PacketHandler'); diff --git a/src/client/voice/util/DispatcherSet.js b/src/client/voice/util/DispatcherSet.js index a1ab7e943..38a7c8b6a 100644 --- a/src/client/voice/util/DispatcherSet.js +++ b/src/client/voice/util/DispatcherSet.js @@ -1,3 +1,5 @@ +'use strict'; + const { Events } = require('../../../util/Constants'); /** diff --git a/src/client/voice/util/PlayInterface.js b/src/client/voice/util/PlayInterface.js index 58d31141e..ac66eb290 100644 --- a/src/client/voice/util/PlayInterface.js +++ b/src/client/voice/util/PlayInterface.js @@ -1,3 +1,5 @@ +'use strict'; + const { Readable } = require('stream'); const prism = require('prism-media'); const { Error } = require('../../../errors'); diff --git a/src/client/voice/util/Secretbox.js b/src/client/voice/util/Secretbox.js index fe1eebe84..1b30eeb60 100644 --- a/src/client/voice/util/Secretbox.js +++ b/src/client/voice/util/Secretbox.js @@ -1,3 +1,5 @@ +'use strict'; + const libs = { sodium: sodium => ({ open: sodium.api.crypto_secretbox_open_easy, diff --git a/src/client/voice/util/Silence.js b/src/client/voice/util/Silence.js index b9643da17..2068d7630 100644 --- a/src/client/voice/util/Silence.js +++ b/src/client/voice/util/Silence.js @@ -1,3 +1,5 @@ +'use strict'; + const { Readable } = require('stream'); const SILENCE_FRAME = Buffer.from([0xF8, 0xFF, 0xFE]); diff --git a/src/client/voice/util/VolumeInterface.js b/src/client/voice/util/VolumeInterface.js index 95645f91e..a631e6caf 100644 --- a/src/client/voice/util/VolumeInterface.js +++ b/src/client/voice/util/VolumeInterface.js @@ -1,3 +1,5 @@ +'use strict'; + const EventEmitter = require('events'); /** diff --git a/src/client/websocket/WebSocketManager.js b/src/client/websocket/WebSocketManager.js index 891da3f45..fd7499682 100644 --- a/src/client/websocket/WebSocketManager.js +++ b/src/client/websocket/WebSocketManager.js @@ -1,3 +1,5 @@ +'use strict'; + const Collection = require('../../util/Collection'); const WebSocketShard = require('./WebSocketShard'); const { Events, Status, WSEvents } = require('../../util/Constants'); diff --git a/src/client/websocket/WebSocketShard.js b/src/client/websocket/WebSocketShard.js index 7aec37e25..6237b0516 100644 --- a/src/client/websocket/WebSocketShard.js +++ b/src/client/websocket/WebSocketShard.js @@ -1,3 +1,5 @@ +'use strict'; + const EventEmitter = require('events'); const WebSocket = require('../../WebSocket'); const { Status, Events, OPCodes, WSEvents, WSCodes } = require('../../util/Constants'); diff --git a/src/client/websocket/handlers/CHANNEL_CREATE.js b/src/client/websocket/handlers/CHANNEL_CREATE.js index 3074254fc..d6d560d8e 100644 --- a/src/client/websocket/handlers/CHANNEL_CREATE.js +++ b/src/client/websocket/handlers/CHANNEL_CREATE.js @@ -1,3 +1,5 @@ +'use strict'; + module.exports = (client, packet) => { client.actions.ChannelCreate.handle(packet.d); }; diff --git a/src/client/websocket/handlers/CHANNEL_DELETE.js b/src/client/websocket/handlers/CHANNEL_DELETE.js index 158ccb352..cb9f3d8c1 100644 --- a/src/client/websocket/handlers/CHANNEL_DELETE.js +++ b/src/client/websocket/handlers/CHANNEL_DELETE.js @@ -1,3 +1,5 @@ +'use strict'; + module.exports = (client, packet) => { client.actions.ChannelDelete.handle(packet.d); }; diff --git a/src/client/websocket/handlers/CHANNEL_PINS_UPDATE.js b/src/client/websocket/handlers/CHANNEL_PINS_UPDATE.js index 1272dbbb1..dfc854e37 100644 --- a/src/client/websocket/handlers/CHANNEL_PINS_UPDATE.js +++ b/src/client/websocket/handlers/CHANNEL_PINS_UPDATE.js @@ -1,3 +1,5 @@ +'use strict'; + const { Events } = require('../../../util/Constants'); module.exports = (client, { d: data }) => { diff --git a/src/client/websocket/handlers/CHANNEL_UPDATE.js b/src/client/websocket/handlers/CHANNEL_UPDATE.js index 46d9037a2..b437ebbde 100644 --- a/src/client/websocket/handlers/CHANNEL_UPDATE.js +++ b/src/client/websocket/handlers/CHANNEL_UPDATE.js @@ -1,3 +1,5 @@ +'use strict'; + const { Events } = require('../../../util/Constants'); module.exports = (client, packet) => { diff --git a/src/client/websocket/handlers/GUILD_BAN_ADD.js b/src/client/websocket/handlers/GUILD_BAN_ADD.js index 00772c8cc..4fa89edcf 100644 --- a/src/client/websocket/handlers/GUILD_BAN_ADD.js +++ b/src/client/websocket/handlers/GUILD_BAN_ADD.js @@ -1,3 +1,5 @@ +'use strict'; + const { Events } = require('../../../util/Constants'); module.exports = (client, { d: data }) => { diff --git a/src/client/websocket/handlers/GUILD_BAN_REMOVE.js b/src/client/websocket/handlers/GUILD_BAN_REMOVE.js index 08483a835..8389e46e8 100644 --- a/src/client/websocket/handlers/GUILD_BAN_REMOVE.js +++ b/src/client/websocket/handlers/GUILD_BAN_REMOVE.js @@ -1,3 +1,5 @@ +'use strict'; + module.exports = (client, packet) => { client.actions.GuildBanRemove.handle(packet.d); }; diff --git a/src/client/websocket/handlers/GUILD_CREATE.js b/src/client/websocket/handlers/GUILD_CREATE.js index 05250ed6e..9f13c6581 100644 --- a/src/client/websocket/handlers/GUILD_CREATE.js +++ b/src/client/websocket/handlers/GUILD_CREATE.js @@ -1,3 +1,5 @@ +'use strict'; + const { Events, Status } = require('../../../util/Constants'); module.exports = async (client, { d: data }, shard) => { diff --git a/src/client/websocket/handlers/GUILD_DELETE.js b/src/client/websocket/handlers/GUILD_DELETE.js index 19d1b3b0a..27a325623 100644 --- a/src/client/websocket/handlers/GUILD_DELETE.js +++ b/src/client/websocket/handlers/GUILD_DELETE.js @@ -1,3 +1,5 @@ +'use strict'; + module.exports = (client, packet) => { client.actions.GuildDelete.handle(packet.d); }; diff --git a/src/client/websocket/handlers/GUILD_EMOJIS_UPDATE.js b/src/client/websocket/handlers/GUILD_EMOJIS_UPDATE.js index 5fa5a9d54..e23b6713f 100644 --- a/src/client/websocket/handlers/GUILD_EMOJIS_UPDATE.js +++ b/src/client/websocket/handlers/GUILD_EMOJIS_UPDATE.js @@ -1,3 +1,5 @@ +'use strict'; + module.exports = (client, packet) => { client.actions.GuildEmojisUpdate.handle(packet.d); }; diff --git a/src/client/websocket/handlers/GUILD_INTEGRATIONS_UPDATE.js b/src/client/websocket/handlers/GUILD_INTEGRATIONS_UPDATE.js index 6c1a0cfd3..e90a72c25 100644 --- a/src/client/websocket/handlers/GUILD_INTEGRATIONS_UPDATE.js +++ b/src/client/websocket/handlers/GUILD_INTEGRATIONS_UPDATE.js @@ -1,3 +1,5 @@ +'use strict'; + module.exports = (client, packet) => { client.actions.GuildIntegrationsUpdate.handle(packet.d); }; diff --git a/src/client/websocket/handlers/GUILD_MEMBERS_CHUNK.js b/src/client/websocket/handlers/GUILD_MEMBERS_CHUNK.js index 7178264d2..0738eaa67 100644 --- a/src/client/websocket/handlers/GUILD_MEMBERS_CHUNK.js +++ b/src/client/websocket/handlers/GUILD_MEMBERS_CHUNK.js @@ -1,3 +1,5 @@ +'use strict'; + const { Events } = require('../../../util/Constants'); const Collection = require('../../../util/Collection'); diff --git a/src/client/websocket/handlers/GUILD_MEMBER_ADD.js b/src/client/websocket/handlers/GUILD_MEMBER_ADD.js index 367058a5b..796b6c376 100644 --- a/src/client/websocket/handlers/GUILD_MEMBER_ADD.js +++ b/src/client/websocket/handlers/GUILD_MEMBER_ADD.js @@ -1,3 +1,5 @@ +'use strict'; + const { Events, Status } = require('../../../util/Constants'); module.exports = (client, { d: data }, shard) => { diff --git a/src/client/websocket/handlers/GUILD_MEMBER_REMOVE.js b/src/client/websocket/handlers/GUILD_MEMBER_REMOVE.js index b00da0e63..72432af11 100644 --- a/src/client/websocket/handlers/GUILD_MEMBER_REMOVE.js +++ b/src/client/websocket/handlers/GUILD_MEMBER_REMOVE.js @@ -1,3 +1,5 @@ +'use strict'; + module.exports = (client, packet, shard) => { client.actions.GuildMemberRemove.handle(packet.d, shard); }; diff --git a/src/client/websocket/handlers/GUILD_MEMBER_UPDATE.js b/src/client/websocket/handlers/GUILD_MEMBER_UPDATE.js index be4f573ad..9341329a3 100644 --- a/src/client/websocket/handlers/GUILD_MEMBER_UPDATE.js +++ b/src/client/websocket/handlers/GUILD_MEMBER_UPDATE.js @@ -1,3 +1,5 @@ +'use strict'; + const { Status, Events } = require('../../../util/Constants'); module.exports = (client, { d: data }, shard) => { diff --git a/src/client/websocket/handlers/GUILD_ROLE_CREATE.js b/src/client/websocket/handlers/GUILD_ROLE_CREATE.js index b6ea80381..da9e7bc4b 100644 --- a/src/client/websocket/handlers/GUILD_ROLE_CREATE.js +++ b/src/client/websocket/handlers/GUILD_ROLE_CREATE.js @@ -1,3 +1,5 @@ +'use strict'; + module.exports = (client, packet) => { client.actions.GuildRoleCreate.handle(packet.d); }; diff --git a/src/client/websocket/handlers/GUILD_ROLE_DELETE.js b/src/client/websocket/handlers/GUILD_ROLE_DELETE.js index d1093cb27..cdc635316 100644 --- a/src/client/websocket/handlers/GUILD_ROLE_DELETE.js +++ b/src/client/websocket/handlers/GUILD_ROLE_DELETE.js @@ -1,3 +1,5 @@ +'use strict'; + module.exports = (client, packet) => { client.actions.GuildRoleDelete.handle(packet.d); }; diff --git a/src/client/websocket/handlers/GUILD_ROLE_UPDATE.js b/src/client/websocket/handlers/GUILD_ROLE_UPDATE.js index c1f526c57..3a9b62e80 100644 --- a/src/client/websocket/handlers/GUILD_ROLE_UPDATE.js +++ b/src/client/websocket/handlers/GUILD_ROLE_UPDATE.js @@ -1,3 +1,5 @@ +'use strict'; + module.exports = (client, packet) => { client.actions.GuildRoleUpdate.handle(packet.d); }; diff --git a/src/client/websocket/handlers/GUILD_SYNC.js b/src/client/websocket/handlers/GUILD_SYNC.js index f27da424e..b7e7d1b24 100644 --- a/src/client/websocket/handlers/GUILD_SYNC.js +++ b/src/client/websocket/handlers/GUILD_SYNC.js @@ -1,3 +1,5 @@ +'use strict'; + module.exports = (client, packet) => { client.actions.GuildSync.handle(packet.d); }; diff --git a/src/client/websocket/handlers/GUILD_UPDATE.js b/src/client/websocket/handlers/GUILD_UPDATE.js index 0f3e24f74..fd0012ad9 100644 --- a/src/client/websocket/handlers/GUILD_UPDATE.js +++ b/src/client/websocket/handlers/GUILD_UPDATE.js @@ -1,3 +1,5 @@ +'use strict'; + module.exports = (client, packet) => { client.actions.GuildUpdate.handle(packet.d); }; diff --git a/src/client/websocket/handlers/MESSAGE_CREATE.js b/src/client/websocket/handlers/MESSAGE_CREATE.js index bc9303fd5..c9b79a8fa 100644 --- a/src/client/websocket/handlers/MESSAGE_CREATE.js +++ b/src/client/websocket/handlers/MESSAGE_CREATE.js @@ -1,3 +1,5 @@ +'use strict'; + module.exports = (client, packet) => { client.actions.MessageCreate.handle(packet.d); }; diff --git a/src/client/websocket/handlers/MESSAGE_DELETE.js b/src/client/websocket/handlers/MESSAGE_DELETE.js index 09062196c..85ae2bc75 100644 --- a/src/client/websocket/handlers/MESSAGE_DELETE.js +++ b/src/client/websocket/handlers/MESSAGE_DELETE.js @@ -1,3 +1,5 @@ +'use strict'; + module.exports = (client, packet) => { client.actions.MessageDelete.handle(packet.d); }; diff --git a/src/client/websocket/handlers/MESSAGE_DELETE_BULK.js b/src/client/websocket/handlers/MESSAGE_DELETE_BULK.js index a927b3b14..fbcf80fd3 100644 --- a/src/client/websocket/handlers/MESSAGE_DELETE_BULK.js +++ b/src/client/websocket/handlers/MESSAGE_DELETE_BULK.js @@ -1,3 +1,5 @@ +'use strict'; + module.exports = (client, packet) => { client.actions.MessageDeleteBulk.handle(packet.d); }; diff --git a/src/client/websocket/handlers/MESSAGE_REACTION_ADD.js b/src/client/websocket/handlers/MESSAGE_REACTION_ADD.js index e2ac2c07a..6d0bbb059 100644 --- a/src/client/websocket/handlers/MESSAGE_REACTION_ADD.js +++ b/src/client/websocket/handlers/MESSAGE_REACTION_ADD.js @@ -1,3 +1,5 @@ +'use strict'; + const { Events } = require('../../../util/Constants'); module.exports = (client, packet) => { diff --git a/src/client/websocket/handlers/MESSAGE_REACTION_REMOVE.js b/src/client/websocket/handlers/MESSAGE_REACTION_REMOVE.js index 8b9f22a17..2980e6954 100644 --- a/src/client/websocket/handlers/MESSAGE_REACTION_REMOVE.js +++ b/src/client/websocket/handlers/MESSAGE_REACTION_REMOVE.js @@ -1,3 +1,5 @@ +'use strict'; + module.exports = (client, packet) => { client.actions.MessageReactionRemove.handle(packet.d); }; diff --git a/src/client/websocket/handlers/MESSAGE_REACTION_REMOVE_ALL.js b/src/client/websocket/handlers/MESSAGE_REACTION_REMOVE_ALL.js index 2323cfe05..ead80f755 100644 --- a/src/client/websocket/handlers/MESSAGE_REACTION_REMOVE_ALL.js +++ b/src/client/websocket/handlers/MESSAGE_REACTION_REMOVE_ALL.js @@ -1,3 +1,5 @@ +'use strict'; + module.exports = (client, packet) => { client.actions.MessageReactionRemoveAll.handle(packet.d); }; diff --git a/src/client/websocket/handlers/MESSAGE_UPDATE.js b/src/client/websocket/handlers/MESSAGE_UPDATE.js index 9be750c7e..7428e90c8 100644 --- a/src/client/websocket/handlers/MESSAGE_UPDATE.js +++ b/src/client/websocket/handlers/MESSAGE_UPDATE.js @@ -1,3 +1,5 @@ +'use strict'; + const { Events } = require('../../../util/Constants'); module.exports = (client, packet) => { diff --git a/src/client/websocket/handlers/PRESENCE_UPDATE.js b/src/client/websocket/handlers/PRESENCE_UPDATE.js index 89b9f0e25..bde36297d 100644 --- a/src/client/websocket/handlers/PRESENCE_UPDATE.js +++ b/src/client/websocket/handlers/PRESENCE_UPDATE.js @@ -1,3 +1,5 @@ +'use strict'; + module.exports = (client, packet) => { client.actions.PresenceUpdate.handle(packet.d); }; diff --git a/src/client/websocket/handlers/READY.js b/src/client/websocket/handlers/READY.js index f22968d3d..74b1e1b9a 100644 --- a/src/client/websocket/handlers/READY.js +++ b/src/client/websocket/handlers/READY.js @@ -1,3 +1,5 @@ +'use strict'; + let ClientUser; module.exports = (client, { d: data }, shard) => { diff --git a/src/client/websocket/handlers/RESUMED.js b/src/client/websocket/handlers/RESUMED.js index 6cc355e98..bd00ec883 100644 --- a/src/client/websocket/handlers/RESUMED.js +++ b/src/client/websocket/handlers/RESUMED.js @@ -1,3 +1,5 @@ +'use strict'; + const { Events } = require('../../../util/Constants'); module.exports = (client, packet, shard) => { diff --git a/src/client/websocket/handlers/TYPING_START.js b/src/client/websocket/handlers/TYPING_START.js index ac01d30d9..9df76dc75 100644 --- a/src/client/websocket/handlers/TYPING_START.js +++ b/src/client/websocket/handlers/TYPING_START.js @@ -1,3 +1,5 @@ +'use strict'; + const { Events } = require('../../../util/Constants'); module.exports = (client, { d: data }) => { diff --git a/src/client/websocket/handlers/USER_UPDATE.js b/src/client/websocket/handlers/USER_UPDATE.js index 3c5b859c3..a02bf5887 100644 --- a/src/client/websocket/handlers/USER_UPDATE.js +++ b/src/client/websocket/handlers/USER_UPDATE.js @@ -1,3 +1,5 @@ +'use strict'; + module.exports = (client, packet) => { client.actions.UserUpdate.handle(packet.d); }; diff --git a/src/client/websocket/handlers/VOICE_SERVER_UPDATE.js b/src/client/websocket/handlers/VOICE_SERVER_UPDATE.js index c8ac3883c..2663d99aa 100644 --- a/src/client/websocket/handlers/VOICE_SERVER_UPDATE.js +++ b/src/client/websocket/handlers/VOICE_SERVER_UPDATE.js @@ -1,3 +1,5 @@ +'use strict'; + module.exports = (client, packet) => { client.emit('self.voiceServer', packet.d); }; diff --git a/src/client/websocket/handlers/VOICE_STATE_UPDATE.js b/src/client/websocket/handlers/VOICE_STATE_UPDATE.js index a9527adaa..dbff6ea2d 100644 --- a/src/client/websocket/handlers/VOICE_STATE_UPDATE.js +++ b/src/client/websocket/handlers/VOICE_STATE_UPDATE.js @@ -1,3 +1,5 @@ +'use strict'; + module.exports = (client, packet) => { client.actions.VoiceStateUpdate.handle(packet.d); }; diff --git a/src/client/websocket/handlers/WEBHOOKS_UPDATE.js b/src/client/websocket/handlers/WEBHOOKS_UPDATE.js index b1afb91c5..46cacee0b 100644 --- a/src/client/websocket/handlers/WEBHOOKS_UPDATE.js +++ b/src/client/websocket/handlers/WEBHOOKS_UPDATE.js @@ -1,3 +1,5 @@ +'use strict'; + module.exports = (client, packet) => { client.actions.WebhooksUpdate.handle(packet.d); }; diff --git a/src/client/websocket/handlers/index.js b/src/client/websocket/handlers/index.js index 77bcf8fd0..b253cefee 100644 --- a/src/client/websocket/handlers/index.js +++ b/src/client/websocket/handlers/index.js @@ -1,3 +1,5 @@ +'use strict'; + const { WSEvents } = require('../../../util/Constants'); const handlers = {}; diff --git a/src/errors/DJSError.js b/src/errors/DJSError.js index 1d5aea124..157ca6600 100644 --- a/src/errors/DJSError.js +++ b/src/errors/DJSError.js @@ -1,3 +1,5 @@ +'use strict'; + // Heavily inspired by node's `internal/errors` module const kCode = Symbol('code'); diff --git a/src/errors/Messages.js b/src/errors/Messages.js index 5f237ac5b..792c2b8b9 100644 --- a/src/errors/Messages.js +++ b/src/errors/Messages.js @@ -1,3 +1,5 @@ +'use strict'; + const { register } = require('./DJSError'); const Messages = { diff --git a/src/errors/index.js b/src/errors/index.js index 39b7582df..c94ddc788 100644 --- a/src/errors/index.js +++ b/src/errors/index.js @@ -1,2 +1,4 @@ +'use strict'; + module.exports = require('./DJSError'); module.exports.Messages = require('./Messages'); diff --git a/src/index.js b/src/index.js index a124108f6..1747f68c6 100644 --- a/src/index.js +++ b/src/index.js @@ -1,3 +1,5 @@ +'use strict'; + const Util = require('./util/Util'); module.exports = { diff --git a/src/rest/APIRequest.js b/src/rest/APIRequest.js index ec8375dd1..7b0a73e41 100644 --- a/src/rest/APIRequest.js +++ b/src/rest/APIRequest.js @@ -1,3 +1,5 @@ +'use strict'; + const querystring = require('querystring'); const FormData = require('form-data'); const https = require('https'); diff --git a/src/rest/APIRouter.js b/src/rest/APIRouter.js index 06ebeb3f9..715b1c7c4 100644 --- a/src/rest/APIRouter.js +++ b/src/rest/APIRouter.js @@ -1,3 +1,5 @@ +'use strict'; + const noop = () => {}; // eslint-disable-line no-empty-function const methods = ['get', 'post', 'delete', 'patch', 'put']; const reflectors = [ diff --git a/src/rest/DiscordAPIError.js b/src/rest/DiscordAPIError.js index c90ee4f5a..559194f2c 100644 --- a/src/rest/DiscordAPIError.js +++ b/src/rest/DiscordAPIError.js @@ -1,3 +1,5 @@ +'use strict'; + /** * Represents an error from the Discord API. * @extends Error diff --git a/src/rest/HTTPError.js b/src/rest/HTTPError.js index 32b3e6bd8..2911467fc 100644 --- a/src/rest/HTTPError.js +++ b/src/rest/HTTPError.js @@ -1,3 +1,5 @@ +'use strict'; + /** * Represents a HTTP error from a request. * @extends Error diff --git a/src/rest/RESTManager.js b/src/rest/RESTManager.js index 53a8047f5..306fa2468 100644 --- a/src/rest/RESTManager.js +++ b/src/rest/RESTManager.js @@ -1,3 +1,5 @@ +'use strict'; + const RequestHandler = require('./RequestHandler'); const APIRequest = require('./APIRequest'); const routeBuilder = require('./APIRouter'); diff --git a/src/rest/RequestHandler.js b/src/rest/RequestHandler.js index 3f66fd438..44fca4fbc 100644 --- a/src/rest/RequestHandler.js +++ b/src/rest/RequestHandler.js @@ -1,3 +1,5 @@ +'use strict'; + const DiscordAPIError = require('./DiscordAPIError'); const HTTPError = require('./HTTPError'); const Util = require('../util/Util'); diff --git a/src/sharding/Shard.js b/src/sharding/Shard.js index 3b25c1d0a..adc5caeb9 100644 --- a/src/sharding/Shard.js +++ b/src/sharding/Shard.js @@ -1,3 +1,5 @@ +'use strict'; + const EventEmitter = require('events'); const path = require('path'); const Util = require('../util/Util'); diff --git a/src/sharding/ShardClientUtil.js b/src/sharding/ShardClientUtil.js index 201568ca1..026c97efa 100644 --- a/src/sharding/ShardClientUtil.js +++ b/src/sharding/ShardClientUtil.js @@ -1,3 +1,5 @@ +'use strict'; + const Util = require('../util/Util'); const { Events } = require('../util/Constants'); diff --git a/src/sharding/ShardingManager.js b/src/sharding/ShardingManager.js index b71962290..aca3ebed3 100644 --- a/src/sharding/ShardingManager.js +++ b/src/sharding/ShardingManager.js @@ -1,3 +1,5 @@ +'use strict'; + const path = require('path'); const fs = require('fs'); const EventEmitter = require('events'); diff --git a/src/stores/ChannelStore.js b/src/stores/ChannelStore.js index 6e2e4081a..8d491c837 100644 --- a/src/stores/ChannelStore.js +++ b/src/stores/ChannelStore.js @@ -1,3 +1,5 @@ +'use strict'; + const DataStore = require('./DataStore'); const Channel = require('../structures/Channel'); const { Events } = require('../util/Constants'); diff --git a/src/stores/DataStore.js b/src/stores/DataStore.js index 3708893c9..fc841899a 100644 --- a/src/stores/DataStore.js +++ b/src/stores/DataStore.js @@ -1,3 +1,5 @@ +'use strict'; + const Collection = require('../util/Collection'); let Structures; diff --git a/src/stores/GuildChannelStore.js b/src/stores/GuildChannelStore.js index e67bcc1c3..e538889da 100644 --- a/src/stores/GuildChannelStore.js +++ b/src/stores/GuildChannelStore.js @@ -1,3 +1,5 @@ +'use strict'; + const Channel = require('../structures/Channel'); const { ChannelTypes } = require('../util/Constants'); const DataStore = require('./DataStore'); diff --git a/src/stores/GuildEmojiRoleStore.js b/src/stores/GuildEmojiRoleStore.js index e2fe5ecdd..8c097f564 100644 --- a/src/stores/GuildEmojiRoleStore.js +++ b/src/stores/GuildEmojiRoleStore.js @@ -1,3 +1,5 @@ +'use strict'; + const Collection = require('../util/Collection'); const Util = require('../util/Util'); const { TypeError } = require('../errors'); diff --git a/src/stores/GuildEmojiStore.js b/src/stores/GuildEmojiStore.js index 925f79ab9..b992a68c9 100644 --- a/src/stores/GuildEmojiStore.js +++ b/src/stores/GuildEmojiStore.js @@ -1,3 +1,5 @@ +'use strict'; + const Collection = require('../util/Collection'); const DataStore = require('./DataStore'); const GuildEmoji = require('../structures/GuildEmoji'); diff --git a/src/stores/GuildMemberRoleStore.js b/src/stores/GuildMemberRoleStore.js index 205de123f..8789df212 100644 --- a/src/stores/GuildMemberRoleStore.js +++ b/src/stores/GuildMemberRoleStore.js @@ -1,3 +1,5 @@ +'use strict'; + const Collection = require('../util/Collection'); const Util = require('../util/Util'); const { TypeError } = require('../errors'); diff --git a/src/stores/GuildMemberStore.js b/src/stores/GuildMemberStore.js index 6f95aec92..039fb4c7b 100644 --- a/src/stores/GuildMemberStore.js +++ b/src/stores/GuildMemberStore.js @@ -1,3 +1,5 @@ +'use strict'; + const DataStore = require('./DataStore'); const GuildMember = require('../structures/GuildMember'); const { Events, OPCodes } = require('../util/Constants'); diff --git a/src/stores/GuildStore.js b/src/stores/GuildStore.js index 0cf9a1157..90e4358dd 100644 --- a/src/stores/GuildStore.js +++ b/src/stores/GuildStore.js @@ -1,3 +1,5 @@ +'use strict'; + const DataStore = require('./DataStore'); const DataResolver = require('../util/DataResolver'); const { Events } = require('../util/Constants'); diff --git a/src/stores/MessageStore.js b/src/stores/MessageStore.js index 2d7049792..1a8a7083a 100644 --- a/src/stores/MessageStore.js +++ b/src/stores/MessageStore.js @@ -1,3 +1,5 @@ +'use strict'; + const DataStore = require('./DataStore'); const Collection = require('../util/Collection'); const Message = require('../structures/Message'); diff --git a/src/stores/PresenceStore.js b/src/stores/PresenceStore.js index 15fc9f124..061d3f1e9 100644 --- a/src/stores/PresenceStore.js +++ b/src/stores/PresenceStore.js @@ -1,3 +1,5 @@ +'use strict'; + const DataStore = require('./DataStore'); const { Presence } = require('../structures/Presence'); diff --git a/src/stores/ReactionStore.js b/src/stores/ReactionStore.js index 38c467b79..b3910ba4c 100644 --- a/src/stores/ReactionStore.js +++ b/src/stores/ReactionStore.js @@ -1,3 +1,5 @@ +'use strict'; + const DataStore = require('./DataStore'); const MessageReaction = require('../structures/MessageReaction'); diff --git a/src/stores/ReactionUserStore.js b/src/stores/ReactionUserStore.js index 1b0275795..976b79917 100644 --- a/src/stores/ReactionUserStore.js +++ b/src/stores/ReactionUserStore.js @@ -1,3 +1,5 @@ +'use strict'; + const Collection = require('../util/Collection'); const DataStore = require('./DataStore'); const { Error } = require('../errors'); diff --git a/src/stores/RoleStore.js b/src/stores/RoleStore.js index 3c3a5b35a..14956c309 100644 --- a/src/stores/RoleStore.js +++ b/src/stores/RoleStore.js @@ -1,3 +1,5 @@ +'use strict'; + const DataStore = require('./DataStore'); const Role = require('../structures/Role'); const { resolveColor } = require('../util/Util'); diff --git a/src/stores/UserStore.js b/src/stores/UserStore.js index d700877c5..8fd2d9d5a 100644 --- a/src/stores/UserStore.js +++ b/src/stores/UserStore.js @@ -1,3 +1,5 @@ +'use strict'; + const DataStore = require('./DataStore'); const User = require('../structures/User'); const GuildMember = require('../structures/GuildMember'); diff --git a/src/stores/VoiceStateStore.js b/src/stores/VoiceStateStore.js index 2de492495..ece3c2bb6 100644 --- a/src/stores/VoiceStateStore.js +++ b/src/stores/VoiceStateStore.js @@ -1,3 +1,5 @@ +'use strict'; + const DataStore = require('./DataStore'); const VoiceState = require('../structures/VoiceState'); diff --git a/src/structures/APIMessage.js b/src/structures/APIMessage.js index 8b714fcd5..deca5d26d 100644 --- a/src/structures/APIMessage.js +++ b/src/structures/APIMessage.js @@ -1,3 +1,5 @@ +'use strict'; + const DataResolver = require('../util/DataResolver'); const MessageEmbed = require('./MessageEmbed'); const MessageAttachment = require('./MessageAttachment'); diff --git a/src/structures/Base.js b/src/structures/Base.js index 37633757b..4850a39d5 100644 --- a/src/structures/Base.js +++ b/src/structures/Base.js @@ -1,3 +1,5 @@ +'use strict'; + const Util = require('../util/Util'); /** diff --git a/src/structures/CategoryChannel.js b/src/structures/CategoryChannel.js index 5766a4a75..60be408c6 100644 --- a/src/structures/CategoryChannel.js +++ b/src/structures/CategoryChannel.js @@ -1,3 +1,5 @@ +'use strict'; + const GuildChannel = require('./GuildChannel'); /** diff --git a/src/structures/Channel.js b/src/structures/Channel.js index 8466d19af..92914118d 100644 --- a/src/structures/Channel.js +++ b/src/structures/Channel.js @@ -1,3 +1,5 @@ +'use strict'; + const Snowflake = require('../util/Snowflake'); const Base = require('./Base'); const { ChannelTypes } = require('../util/Constants'); diff --git a/src/structures/ClientApplication.js b/src/structures/ClientApplication.js index 7ea360200..d2bcd17a7 100644 --- a/src/structures/ClientApplication.js +++ b/src/structures/ClientApplication.js @@ -1,3 +1,5 @@ +'use strict'; + const Snowflake = require('../util/Snowflake'); const { ClientApplicationAssetTypes, Endpoints } = require('../util/Constants'); const Base = require('./Base'); diff --git a/src/structures/ClientPresence.js b/src/structures/ClientPresence.js index 68dda64c5..a92dfb302 100644 --- a/src/structures/ClientPresence.js +++ b/src/structures/ClientPresence.js @@ -1,3 +1,5 @@ +'use strict'; + const { Presence } = require('./Presence'); const Collection = require('../util/Collection'); const { ActivityTypes, OPCodes } = require('../util/Constants'); diff --git a/src/structures/ClientUser.js b/src/structures/ClientUser.js index 1b8d90d98..79d7ad0e1 100644 --- a/src/structures/ClientUser.js +++ b/src/structures/ClientUser.js @@ -1,3 +1,5 @@ +'use strict'; + const Structures = require('../util/Structures'); const DataResolver = require('../util/DataResolver'); diff --git a/src/structures/DMChannel.js b/src/structures/DMChannel.js index 1f45f490f..5549618a2 100644 --- a/src/structures/DMChannel.js +++ b/src/structures/DMChannel.js @@ -1,3 +1,5 @@ +'use strict'; + const Channel = require('./Channel'); const TextBasedChannel = require('./interfaces/TextBasedChannel'); const MessageStore = require('../stores/MessageStore'); diff --git a/src/structures/Emoji.js b/src/structures/Emoji.js index ed844f18a..803fc5002 100644 --- a/src/structures/Emoji.js +++ b/src/structures/Emoji.js @@ -1,3 +1,5 @@ +'use strict'; + const Snowflake = require('../util/Snowflake'); const Base = require('./Base'); diff --git a/src/structures/GroupDMChannel.js b/src/structures/GroupDMChannel.js index b2fe7200f..6f9aca390 100644 --- a/src/structures/GroupDMChannel.js +++ b/src/structures/GroupDMChannel.js @@ -1,3 +1,5 @@ +'use strict'; + const Channel = require('./Channel'); const TextBasedChannel = require('./interfaces/TextBasedChannel'); const Collection = require('../util/Collection'); diff --git a/src/structures/Guild.js b/src/structures/Guild.js index a194ea15a..aef0b3113 100644 --- a/src/structures/Guild.js +++ b/src/structures/Guild.js @@ -1,3 +1,5 @@ +'use strict'; + const Invite = require('./Invite'); const Integration = require('./Integration'); const GuildAuditLogs = require('./GuildAuditLogs'); diff --git a/src/structures/GuildAuditLogs.js b/src/structures/GuildAuditLogs.js index a5212d5b4..f78078a7c 100644 --- a/src/structures/GuildAuditLogs.js +++ b/src/structures/GuildAuditLogs.js @@ -1,3 +1,5 @@ +'use strict'; + const Collection = require('../util/Collection'); const Snowflake = require('../util/Snowflake'); const Webhook = require('./Webhook'); diff --git a/src/structures/GuildChannel.js b/src/structures/GuildChannel.js index daf20a52d..dc0a4e415 100644 --- a/src/structures/GuildChannel.js +++ b/src/structures/GuildChannel.js @@ -1,3 +1,5 @@ +'use strict'; + const Channel = require('./Channel'); const Role = require('./Role'); const Invite = require('./Invite'); diff --git a/src/structures/GuildEmoji.js b/src/structures/GuildEmoji.js index 93e8d275d..24fd7c02a 100644 --- a/src/structures/GuildEmoji.js +++ b/src/structures/GuildEmoji.js @@ -1,3 +1,5 @@ +'use strict'; + const GuildEmojiRoleStore = require('../stores/GuildEmojiRoleStore'); const Permissions = require('../util/Permissions'); const { Error } = require('../errors'); diff --git a/src/structures/GuildMember.js b/src/structures/GuildMember.js index a2e82d793..d91071c93 100644 --- a/src/structures/GuildMember.js +++ b/src/structures/GuildMember.js @@ -1,3 +1,5 @@ +'use strict'; + const TextBasedChannel = require('./interfaces/TextBasedChannel'); const Role = require('./Role'); const Permissions = require('../util/Permissions'); diff --git a/src/structures/Integration.js b/src/structures/Integration.js index 2782008ba..5ff760dc7 100644 --- a/src/structures/Integration.js +++ b/src/structures/Integration.js @@ -1,3 +1,5 @@ +'use strict'; + const Base = require('./Base'); /** diff --git a/src/structures/Invite.js b/src/structures/Invite.js index b142d6960..fec3f2d7d 100644 --- a/src/structures/Invite.js +++ b/src/structures/Invite.js @@ -1,3 +1,5 @@ +'use strict'; + const { Endpoints } = require('../util/Constants'); const Base = require('./Base'); diff --git a/src/structures/Message.js b/src/structures/Message.js index 88a1707a9..1947705ec 100644 --- a/src/structures/Message.js +++ b/src/structures/Message.js @@ -1,3 +1,5 @@ +'use strict'; + const Mentions = require('./MessageMentions'); const MessageAttachment = require('./MessageAttachment'); const Embed = require('./MessageEmbed'); diff --git a/src/structures/MessageAttachment.js b/src/structures/MessageAttachment.js index cce6e487b..a4c053036 100644 --- a/src/structures/MessageAttachment.js +++ b/src/structures/MessageAttachment.js @@ -1,3 +1,5 @@ +'use strict'; + const Util = require('../util/Util'); /** diff --git a/src/structures/MessageCollector.js b/src/structures/MessageCollector.js index 3d9fcf727..59120b9db 100644 --- a/src/structures/MessageCollector.js +++ b/src/structures/MessageCollector.js @@ -1,3 +1,5 @@ +'use strict'; + const Collector = require('./interfaces/Collector'); const { Events } = require('../util/Constants'); diff --git a/src/structures/MessageEmbed.js b/src/structures/MessageEmbed.js index 49ddf30a7..213a27a1d 100644 --- a/src/structures/MessageEmbed.js +++ b/src/structures/MessageEmbed.js @@ -1,3 +1,5 @@ +'use strict'; + const Util = require('../util/Util'); const { RangeError } = require('../errors'); diff --git a/src/structures/MessageMentions.js b/src/structures/MessageMentions.js index bd99397d7..b4414a3bb 100644 --- a/src/structures/MessageMentions.js +++ b/src/structures/MessageMentions.js @@ -1,3 +1,5 @@ +'use strict'; + const Collection = require('../util/Collection'); const Util = require('../util/Util'); const GuildMember = require('./GuildMember'); diff --git a/src/structures/MessageReaction.js b/src/structures/MessageReaction.js index faf3bfbfb..69138fda2 100644 --- a/src/structures/MessageReaction.js +++ b/src/structures/MessageReaction.js @@ -1,3 +1,5 @@ +'use strict'; + const GuildEmoji = require('./GuildEmoji'); const Util = require('../util/Util'); const ReactionEmoji = require('./ReactionEmoji'); diff --git a/src/structures/PermissionOverwrites.js b/src/structures/PermissionOverwrites.js index b28517864..cf11eaa94 100644 --- a/src/structures/PermissionOverwrites.js +++ b/src/structures/PermissionOverwrites.js @@ -1,3 +1,5 @@ +'use strict'; + const Role = require('./Role'); const Permissions = require('../util/Permissions'); const Util = require('../util/Util'); diff --git a/src/structures/Presence.js b/src/structures/Presence.js index 339981340..122b461d5 100644 --- a/src/structures/Presence.js +++ b/src/structures/Presence.js @@ -1,3 +1,5 @@ +'use strict'; + const Util = require('../util/Util'); const ActivityFlags = require('../util/ActivityFlags'); const { ActivityTypes } = require('../util/Constants'); diff --git a/src/structures/ReactionCollector.js b/src/structures/ReactionCollector.js index 5c4532e2f..b4826100f 100644 --- a/src/structures/ReactionCollector.js +++ b/src/structures/ReactionCollector.js @@ -1,3 +1,5 @@ +'use strict'; + const Collector = require('./interfaces/Collector'); const Collection = require('../util/Collection'); const { Events } = require('../util/Constants'); diff --git a/src/structures/ReactionEmoji.js b/src/structures/ReactionEmoji.js index c6ea8d68f..2661fa91d 100644 --- a/src/structures/ReactionEmoji.js +++ b/src/structures/ReactionEmoji.js @@ -1,3 +1,5 @@ +'use strict'; + const Util = require('../util/Util'); const Emoji = require('./Emoji'); diff --git a/src/structures/Role.js b/src/structures/Role.js index 18f68f2f9..cbae56969 100644 --- a/src/structures/Role.js +++ b/src/structures/Role.js @@ -1,3 +1,5 @@ +'use strict'; + const Snowflake = require('../util/Snowflake'); const Permissions = require('../util/Permissions'); const Util = require('../util/Util'); diff --git a/src/structures/TextChannel.js b/src/structures/TextChannel.js index 6e053e5d0..47c8e19c2 100644 --- a/src/structures/TextChannel.js +++ b/src/structures/TextChannel.js @@ -1,3 +1,5 @@ +'use strict'; + const GuildChannel = require('./GuildChannel'); const Webhook = require('./Webhook'); const TextBasedChannel = require('./interfaces/TextBasedChannel'); diff --git a/src/structures/User.js b/src/structures/User.js index 673663234..22ea5c81a 100644 --- a/src/structures/User.js +++ b/src/structures/User.js @@ -1,3 +1,5 @@ +'use strict'; + const TextBasedChannel = require('./interfaces/TextBasedChannel'); const { Presence } = require('./Presence'); const Snowflake = require('../util/Snowflake'); diff --git a/src/structures/VoiceChannel.js b/src/structures/VoiceChannel.js index aee01b6f0..cf9b1ee99 100644 --- a/src/structures/VoiceChannel.js +++ b/src/structures/VoiceChannel.js @@ -1,3 +1,5 @@ +'use strict'; + const GuildChannel = require('./GuildChannel'); const { browser } = require('../util/Constants'); const Permissions = require('../util/Permissions'); diff --git a/src/structures/VoiceRegion.js b/src/structures/VoiceRegion.js index b4db21770..9626195da 100644 --- a/src/structures/VoiceRegion.js +++ b/src/structures/VoiceRegion.js @@ -1,3 +1,5 @@ +'use strict'; + const Util = require('../util/Util'); /** diff --git a/src/structures/VoiceState.js b/src/structures/VoiceState.js index 88e0ed196..82f9eec71 100644 --- a/src/structures/VoiceState.js +++ b/src/structures/VoiceState.js @@ -1,3 +1,5 @@ +'use strict'; + const Base = require('./Base'); /** diff --git a/src/structures/Webhook.js b/src/structures/Webhook.js index c12cc67f8..7b851c770 100644 --- a/src/structures/Webhook.js +++ b/src/structures/Webhook.js @@ -1,3 +1,5 @@ +'use strict'; + const DataResolver = require('../util/DataResolver'); const Channel = require('./Channel'); const APIMessage = require('./APIMessage'); diff --git a/src/structures/interfaces/Collector.js b/src/structures/interfaces/Collector.js index c490ebb3c..1dbd61429 100644 --- a/src/structures/interfaces/Collector.js +++ b/src/structures/interfaces/Collector.js @@ -1,3 +1,5 @@ +'use strict'; + const Collection = require('../../util/Collection'); const Util = require('../../util/Util'); const EventEmitter = require('events'); diff --git a/src/structures/interfaces/TextBasedChannel.js b/src/structures/interfaces/TextBasedChannel.js index f9c668de3..075bc6752 100644 --- a/src/structures/interfaces/TextBasedChannel.js +++ b/src/structures/interfaces/TextBasedChannel.js @@ -1,3 +1,5 @@ +'use strict'; + const MessageCollector = require('../MessageCollector'); const Snowflake = require('../../util/Snowflake'); const Collection = require('../../util/Collection'); diff --git a/src/util/ActivityFlags.js b/src/util/ActivityFlags.js index 49fd7a678..f6f5aac9e 100644 --- a/src/util/ActivityFlags.js +++ b/src/util/ActivityFlags.js @@ -1,3 +1,5 @@ +'use strict'; + const BitField = require('./BitField'); /** diff --git a/src/util/BitField.js b/src/util/BitField.js index fa506a2e8..96b07b829 100644 --- a/src/util/BitField.js +++ b/src/util/BitField.js @@ -1,3 +1,5 @@ +'use strict'; + const { RangeError } = require('../errors'); /** diff --git a/src/util/Collection.js b/src/util/Collection.js index 7f0570d6c..3d01ffef0 100644 --- a/src/util/Collection.js +++ b/src/util/Collection.js @@ -1,3 +1,5 @@ +'use strict'; + const Util = require('./Util'); /** diff --git a/src/util/Constants.js b/src/util/Constants.js index 01ff57d6f..aac3f5b34 100644 --- a/src/util/Constants.js +++ b/src/util/Constants.js @@ -1,3 +1,5 @@ +'use strict'; + const Package = exports.Package = require('../../package.json'); const { Error, RangeError } = require('../errors'); const browser = exports.browser = typeof window !== 'undefined'; diff --git a/src/util/DataResolver.js b/src/util/DataResolver.js index 5fcfd0d43..1b9057270 100644 --- a/src/util/DataResolver.js +++ b/src/util/DataResolver.js @@ -1,3 +1,5 @@ +'use strict'; + const path = require('path'); const fs = require('fs'); const fetch = require('node-fetch'); diff --git a/src/util/Permissions.js b/src/util/Permissions.js index 295346b16..9f01df399 100644 --- a/src/util/Permissions.js +++ b/src/util/Permissions.js @@ -1,3 +1,5 @@ +'use strict'; + const BitField = require('./BitField'); /** diff --git a/src/util/Snowflake.js b/src/util/Snowflake.js index 00f22d06f..06612c30b 100644 --- a/src/util/Snowflake.js +++ b/src/util/Snowflake.js @@ -1,3 +1,5 @@ +'use strict'; + const Util = require('../util/Util'); // Discord epoch (2015-01-01T00:00:00.000Z) diff --git a/src/util/Speaking.js b/src/util/Speaking.js index e0e557eaa..c706d9953 100644 --- a/src/util/Speaking.js +++ b/src/util/Speaking.js @@ -1,3 +1,5 @@ +'use strict'; + const BitField = require('./BitField'); /** diff --git a/src/util/Structures.js b/src/util/Structures.js index 8b1edd8b5..5bdf5c86a 100644 --- a/src/util/Structures.js +++ b/src/util/Structures.js @@ -1,3 +1,5 @@ +'use strict'; + /** * Allows for the extension of built-in Discord.js structures that are instantiated by {@link DataStore DataStores}. */ diff --git a/src/util/Util.js b/src/util/Util.js index 562b81a41..1d7b7aeeb 100644 --- a/src/util/Util.js +++ b/src/util/Util.js @@ -1,3 +1,5 @@ +'use strict'; + const { Colors, DefaultOptions, Endpoints } = require('./Constants'); const fetch = require('node-fetch'); const { Error: DiscordError, RangeError, TypeError } = require('../errors'); diff --git a/webpack.config.js b/webpack.config.js index c7416852d..c95745f11 100644 --- a/webpack.config.js +++ b/webpack.config.js @@ -1,3 +1,5 @@ +'use strict'; + const path = require('path'); const webpack = require('webpack'); const TerserJSPlugin = require('terser-webpack-plugin');