Skip to content

Commit

Permalink
feat: disable dm for slash
Browse files Browse the repository at this point in the history
  • Loading branch information
fieztazica committed May 12, 2024
1 parent 546a4f9 commit 098db2c
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions src/lib/HootClient.ts
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,10 @@ export class HootClient extends SapphireClient {

dev && ApplicationCommandRegistries.setDefaultGuildIds([process.env.DEV_GUILD_ID]);

for (const command of container.stores.get('commands').values()) {
command.applicationCommandRegistry.registerChatInputCommand((b) => b.setDMPermission(false));
}

ApplicationCommandRegistries.registries.forEach((r) => r.registerChatInputCommand((b) => b.setDMPermission(false)));
}
}
Expand Down

0 comments on commit 098db2c

Please sign in to comment.