are the isCommand() is isText() etc, functions are going to get deprecated?

i recall seeing this somewhere, but either im going crazy and i can't find it anywhere.
29 Replies
Gizzi
Gizzi2y ago
Crazy?
d.js toolkit
d.js toolkit2y ago
- What's your exact discord.js npm list discord.js and node node -v version? - Post the full error stack trace, not just the top part! - Show your code! - Explain what exactly your issue is. - Not a discord.js issue? Check out #useful-servers. - Issue solved? Press the button!
Gizzi
Gizzi2y ago
I was crazy once, They locked me in a room, a rubber room, a rubber room with rats, and rats make me crazy.
Blockzilla
BlockzillaOP2y ago
oof
treble/luna
treble/luna2y ago
they already are its isTextBased() now
Blockzilla
BlockzillaOP2y ago
wait was it only for channels?
treble/luna
treble/luna2y ago
also for commands
Blockzilla
BlockzillaOP2y ago
and that version hasnt been released yet? because on 14.11 it doesnt show up as being deprecated
treble/luna
treble/luna2y ago
The functions do not exist anymore
Syjalo
Syjalo2y ago
Type guards that just thing.type === something are deprecaed in v13 and removed in v14
Blockzilla
BlockzillaOP2y ago
they still show up for me on vscode and im pretty sure im on the latest version because i created a new project & installed d.js just now
treble/luna
treble/luna2y ago
run npm ls discord.js
Blockzilla
BlockzillaOP2y ago
treble/luna
treble/luna2y ago
i dont know what you're doing, but those functions do not exist https://old.discordjs.dev/#/docs/discord.js/14.11.0/class/TextChannel you can see it for yourself there
Blockzilla
BlockzillaOP2y ago
Syjalo
Syjalo2y ago
<Interaction>.isCommand() is there because there're other guards that based on it, like <Interaction>.isChatInputCommand()
Blockzilla
BlockzillaOP2y ago
oh so some of them got removed?
treble/luna
treble/luna2y ago
you're comparing a type to a boolean
Blockzilla
BlockzillaOP2y ago
i know that
treble/luna
treble/luna2y ago
well then don tdo that
Blockzilla
BlockzillaOP2y ago
im trying to show that isCommand still exists according to vscode
treble/luna
treble/luna2y ago
on BaseInteraction it exists yes but that is unreliable as it also includes any context menu command
Blockzilla
BlockzillaOP2y ago
so, some of the is stuff got removed then? ill just use the .type to check it
treble/luna
treble/luna2y ago
better to typeguard .
Blockzilla
BlockzillaOP2y ago
brain.exe has stopped working
treble/luna
treble/luna2y ago
use the .isChatInputCommand etc typeguards instead of comparting the types
Blockzilla
BlockzillaOP2y ago
i dont get which of the two is removed since both show up for me should be using the is stuff for everything?
treble/luna
treble/luna2y ago
the type is still valid but it isnt recognised by ts
Blockzilla
BlockzillaOP2y ago
ah i see, ill just use the is one then
Want results from more Discord servers?
Add your server