diff --git a/.changeset/silent-sheep-study.md b/.changeset/silent-sheep-study.md new file mode 100644 index 00000000..6cd624ea --- /dev/null +++ b/.changeset/silent-sheep-study.md @@ -0,0 +1,5 @@ +--- +"@buape/carbon": patch +--- + +fix: don't let new entry point commands block diff --git a/packages/carbon/src/abstracts/BaseCommand.ts b/packages/carbon/src/abstracts/BaseCommand.ts index 45d5453d..a07fe450 100644 --- a/packages/carbon/src/abstracts/BaseCommand.ts +++ b/packages/carbon/src/abstracts/BaseCommand.ts @@ -68,6 +68,9 @@ export abstract class BaseCommand { * @internal */ serialize() { + if (this.type === ApplicationCommandType.PrimaryEntryPoint) { + throw new Error("Primary Entry Point commands cannot be serialized") + } // Only chat input commands can have descriptions if (this.type === ApplicationCommandType.ChatInput) { const data: RESTPostAPIApplicationCommandsJSONBody = {