Skip to content

Commit

Permalink
Change some commands to be user install only
Browse files Browse the repository at this point in the history
  • Loading branch information
Rian8337 committed Nov 24, 2024
1 parent d60c677 commit a373beb
Show file tree
Hide file tree
Showing 3 changed files with 17 additions and 3 deletions.
Original file line number Diff line number Diff line change
@@ -1,5 +1,8 @@
import { Config } from "@core/Config";
import { ApplicationCommandOptionType } from "discord.js";
import {
ApplicationCommandOptionType,
ApplicationIntegrationType,
} from "discord.js";
import { CommandCategory } from "@enums/core/CommandCategory";
import { SlashCommand } from "structures/core/SlashCommand";
import { MessageCreator } from "@utils/creators/MessageCreator";
Expand Down Expand Up @@ -53,4 +56,5 @@ export const config: SlashCommand["config"] = {
},
],
permissions: ["BotOwner"],
integrationTypes: [ApplicationIntegrationType.UserInstall],
};
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
import { Constants } from "@core/Constants";
import { ApplicationCommandOptionType } from "discord.js";
import {
ApplicationCommandOptionType,
ApplicationIntegrationType,
InteractionContextType,
} from "discord.js";
import { CommandCategory } from "@enums/core/CommandCategory";
import { SlashCommand } from "structures/core/SlashCommand";
import { CommandHelper } from "@utils/helpers/CommandHelper";
Expand Down Expand Up @@ -75,4 +79,6 @@ export const config: SlashCommand["config"] = {
},
],
permissions: ["BotOwner"],
contexts: [InteractionContextType.Guild],
integrationTypes: [ApplicationIntegrationType.UserInstall],
};
6 changes: 5 additions & 1 deletion src/interactions/commands/Bot Creators/unbind/unbind.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,10 @@ import { DatabaseManager } from "@database/DatabaseManager";
import { CommandCategory } from "@enums/core/CommandCategory";
import { SlashCommand } from "structures/core/SlashCommand";
import { MessageCreator } from "@utils/creators/MessageCreator";
import { ApplicationCommandOptionType } from "discord.js";
import {
ApplicationCommandOptionType,
ApplicationIntegrationType,
} from "discord.js";
import { Constants } from "@core/Constants";
import { NumberHelper } from "@utils/helpers/NumberHelper";
import { UnbindLocalization } from "@localization/interactions/commands/Bot Creators/unbind/UnbindLocalization";
Expand Down Expand Up @@ -90,4 +93,5 @@ export const config: SlashCommand["config"] = {
},
],
permissions: ["BotOwner"],
integrationTypes: [ApplicationIntegrationType.UserInstall],
};

0 comments on commit a373beb

Please sign in to comment.