diff --git a/apps/docs/pages/docs/command-file-setup.mdx b/apps/docs/pages/docs/command-file-setup.mdx index 6513f3fe..0262dc9d 100644 --- a/apps/docs/pages/docs/command-file-setup.mdx +++ b/apps/docs/pages/docs/command-file-setup.mdx @@ -83,12 +83,12 @@ Here's an example `content` command which replies with the content of the target ```js filename="commands/misc/content.js" copy - const { CommandType } = require('commandkit'); - + const { ApplicationCommandType } = require("discord.js"); + module.exports = { data: { name: 'content', - type: CommandType.Message, + type: ApplicationCommandType.Message, }, run: ({ interaction, client, handler }) => { @@ -107,15 +107,15 @@ Here's an example `content` command which replies with the content of the target ```js filename="commands/misc/content.js" copy - import { CommandType } from 'commandkit'; + import { ApplicationCommandType } from "discord.js"; export const data = { name: 'content', - type: CommandType.Message, + type: ApplicationCommandType.Message, } export function run({ interaction, client, handler }) { - interaction.reply(`The message is: ${interaction.targetMessage}`); + interaction.reply(`The message is: ${interaction.targetMessage.content}`); } export const options = { @@ -129,15 +129,16 @@ Here's an example `content` command which replies with the content of the target ```ts filename="commands/misc/content.ts" copy - import { CommandType, type CommandData, type ContextMenuCommandProps, type CommandOptions } from 'commandkit'; + import { type CommandData, type ContextMenuCommandProps, type CommandOptions } from "commandkit"; + import { ApplicationCommandType } from "discord.js"; export const data: CommandData = { name: 'content', - type: CommandType.Message, + type: ApplicationCommandType.Message, } export function run({ interaction, client, handler }: ContextMenuCommandProps) { - interaction.reply(`The message is: ${interaction.targetMessage}`); + interaction.reply(`The message is: ${interaction.targetMessage.content}`); } export const options: CommandOptions = {