Skip to content

Commit

Permalink
refactor(actions): removed unnecessary actions
Browse files Browse the repository at this point in the history
Removed actions that were only being used in their
respective websocket handlers. The remaining
actions either were either being used elsewhere or
were using methods from the `GenericAction` class.
  • Loading branch information
almeidx committed Dec 27, 2024
1 parent c484e3d commit d03c4e4
Show file tree
Hide file tree
Showing 48 changed files with 459 additions and 763 deletions.
23 changes: 0 additions & 23 deletions packages/discord.js/src/client/actions/ActionsManager.js
Original file line number Diff line number Diff line change
Expand Up @@ -11,36 +11,20 @@ class ActionsManager {
constructor(client) {
this.client = client;

this.register(require('./ApplicationCommandPermissionsUpdate'));
this.register(require('./AutoModerationActionExecution'));
this.register(require('./AutoModerationRuleCreate'));
this.register(require('./AutoModerationRuleDelete'));
this.register(require('./AutoModerationRuleUpdate'));
this.register(require('./ChannelCreate'));
this.register(require('./ChannelDelete'));
this.register(require('./ChannelUpdate'));
this.register(require('./EntitlementCreate'));
this.register(require('./EntitlementDelete'));
this.register(require('./EntitlementUpdate'));
this.register(require('./GuildAuditLogEntryCreate'));
this.register(require('./GuildBanAdd'));
this.register(require('./GuildBanRemove'));
this.register(require('./GuildChannelsPositionUpdate'));
this.register(require('./GuildDelete'));
this.register(require('./GuildEmojiCreate'));
this.register(require('./GuildEmojiDelete'));
this.register(require('./GuildEmojiUpdate'));
this.register(require('./GuildEmojisUpdate'));
this.register(require('./GuildIntegrationsUpdate'));
this.register(require('./GuildMemberRemove'));
this.register(require('./GuildMemberUpdate'));
this.register(require('./GuildRoleCreate'));
this.register(require('./GuildRoleDelete'));
this.register(require('./GuildRoleUpdate'));
this.register(require('./GuildRolesPositionUpdate'));
this.register(require('./GuildScheduledEventCreate'));
this.register(require('./GuildScheduledEventDelete'));
this.register(require('./GuildScheduledEventUpdate'));
this.register(require('./GuildScheduledEventUserAdd'));
this.register(require('./GuildScheduledEventUserRemove'));
this.register(require('./GuildStickerCreate'));
Expand All @@ -49,8 +33,6 @@ class ActionsManager {
this.register(require('./GuildStickersUpdate'));
this.register(require('./GuildUpdate'));
this.register(require('./InteractionCreate'));
this.register(require('./InviteCreate'));
this.register(require('./InviteDelete'));
this.register(require('./MessageCreate'));
this.register(require('./MessageDelete'));
this.register(require('./MessageDeleteBulk'));
Expand All @@ -66,14 +48,9 @@ class ActionsManager {
this.register(require('./StageInstanceDelete'));
this.register(require('./StageInstanceUpdate'));
this.register(require('./ThreadCreate'));
this.register(require('./ThreadDelete'));
this.register(require('./ThreadListSync'));
this.register(require('./ThreadMemberUpdate'));
this.register(require('./ThreadMembersUpdate'));
this.register(require('./TypingStart'));
this.register(require('./UserUpdate'));
this.register(require('./VoiceStateUpdate'));
this.register(require('./WebhooksUpdate'));
}

register(Action) {
Expand Down

This file was deleted.

This file was deleted.

27 changes: 0 additions & 27 deletions packages/discord.js/src/client/actions/AutoModerationRuleCreate.js

This file was deleted.

31 changes: 0 additions & 31 deletions packages/discord.js/src/client/actions/AutoModerationRuleDelete.js

This file was deleted.

29 changes: 0 additions & 29 deletions packages/discord.js/src/client/actions/AutoModerationRuleUpdate.js

This file was deleted.

23 changes: 0 additions & 23 deletions packages/discord.js/src/client/actions/EntitlementCreate.js

This file was deleted.

27 changes: 0 additions & 27 deletions packages/discord.js/src/client/actions/EntitlementDelete.js

This file was deleted.

25 changes: 0 additions & 25 deletions packages/discord.js/src/client/actions/EntitlementUpdate.js

This file was deleted.

29 changes: 0 additions & 29 deletions packages/discord.js/src/client/actions/GuildAuditLogEntryCreate.js

This file was deleted.

20 changes: 0 additions & 20 deletions packages/discord.js/src/client/actions/GuildBanAdd.js

This file was deleted.

25 changes: 0 additions & 25 deletions packages/discord.js/src/client/actions/GuildBanRemove.js

This file was deleted.

Loading

0 comments on commit d03c4e4

Please sign in to comment.