Update playground for djs v14

This commit is contained in:
Crawron
2022-07-21 16:10:14 -05:00
committed by Darius
parent 43029019f4
commit 5aaaffbda9
2 changed files with 3 additions and 3 deletions

View File

@@ -22,7 +22,7 @@ export function createCommandHandler(client: Client, commands: Command[]) {
})
client.on("interactionCreate", async (interaction) => {
if (!interaction.isCommand()) return
if (!interaction.isChatInputCommand()) return
const command = commands.find(
(command) => command.name === interaction.commandName,

View File

@@ -1,4 +1,4 @@
import { Client } from "discord.js"
import { Client, IntentsBitField } from "discord.js"
import "dotenv/config"
import React from "react"
import { Button, ReacordDiscordJs, useInstance } from "../library/main"
@@ -7,7 +7,7 @@ import { Counter } from "./counter"
import { FruitSelect } from "./fruit-select"
const client = new Client({
intents: ["GUILDS"],
intents: IntentsBitField.Flags.Guilds,
})
const reacord = new ReacordDiscordJs(client)