TypeScript Logical Error Not Syntax Error
So, I have a ModMail bot made in TypeScript, and I have a slash command that blocks the user from D.M.'ing the bot any further. The problem is, when inputting the time/duration for how long the block wants to be in the slash command, the bot disregards it by having the block be permanent.
Please help. The code is below.
Thanks.
17 Replies
• 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.
Message regarding the above code is sent above "d.js tookit's" message.
Unknown User•2y ago
Message Not Public
Sign In & Join Server To View
I already informed you that I do not know how to do so.
Unknown User•2y ago
Message Not Public
Sign In & Join Server To View
Correct!
Unknown User•2y ago
Message Not Public
Sign In & Join Server To View
Gee! It's all clear to me, now! Thanks for your condescending remark that has made it utterly clear to me on how to proceed!
me: go fly a plane
you: i don't know how
me: that's basic flight
how logical
if you don't know how to call a function in javascript (despite the fact that you already do multiple times) I would heavily suggest brushing up on the basics before continuing
#resources / #other-js-ts
please also take note of #rules 3
I did not say I don't know how to call a function. I'm saying I do not know how to implement "setTimeout." This is literally my first day ever hearing about it.
Unknown User•2y ago
Message Not Public
Sign In & Join Server To View
Yes.
No, because there is absolutely no example on that website that is in regards of Discord's API.
Unknown User•2y ago
Message Not Public
Sign In & Join Server To View
I know.
which is to say, as explained on that page, you can pass whatever function you want to
setTimeout
just put the code you want to execute after the timeout in that functionThe code that I sent above I found off a tutorial, so I do not know how to proceed. I am a beginner.
then you should learn the basics before continuing
#resources
please also take note of #rules 3