Skip to content

Commit d826fc0

Browse files
committed
🔨 refactor: remove global commands deletion
1 parent 925c53b commit d826fc0

File tree

3 files changed

+0
-9
lines changed

3 files changed

+0
-9
lines changed

‎.env.production‎

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,4 @@ REGULAR_ROLE_ID=1383170370634514544
1919
GUIDES_TRACKER_PATH=/app/data/guides-tracker.json
2020
ADVENT_OF_CODE_TRACKER_PATH=/app/data/advent-of-code-tracker.json
2121

22-
CLEAR_GLOBAL_COMMANDS=true
23-
2422
# Note: DISCORD_TOKEN & CLIENT_ID should be in .env.local (not committed)

‎src/env.ts‎

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,6 @@ export const config = {
2222
},
2323
serverId: requireEnv('SERVER_ID'),
2424
fetchAndSyncMessages: true,
25-
clearGlobalCommands: optionalEnv('CLEAR_GLOBAL_COMMANDS') === 'true',
2625
guidesTrackerPath: optionalEnv('GUIDES_TRACKER_PATH'),
2726
adventOfCodeTrackerPath: requireEnv('ADVENT_OF_CODE_TRACKER_PATH'),
2827
roleIds: {

‎src/util/deploy.ts‎

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -7,12 +7,6 @@ export async function deployCommands(): Promise<RESTPutAPIApplicationCommandsRes
77

88
const rest = new REST({ version: '10' }).setToken(config.discord.token);
99

10-
if (config.clearGlobalCommands) {
11-
console.log('Clearing global commands...');
12-
await rest.put(Routes.applicationCommands(config.discord.clientId), { body: [] });
13-
console.log('Global commands cleared.');
14-
}
15-
1610
const result = (await rest.put(
1711
Routes.applicationGuildCommands(config.discord.clientId, config.serverId),
1812
{

0 commit comments

Comments
 (0)