#I said that way you are trying to defer

1 messages · Page 1 of 1 (latest)

heavy sun
#

Thonk ```diff

  • await interaction.deferReply();
  • await interaction.reply({...});
  • await interaction.editReply({...});
#

anything you have put in reply brackets🤷‍♂️

#

yes it is
but why you need to defer if it gets executed right after interaction sent

#

so you have to defer reply in the start and use await interaction.editReply({ embeds: [embed], components: [menu] }); instead of thing you have rn

#

no? how will you access to the interaction then

#

show context

#

Why do you need to defer the reply?
By default, discord gives you only 3 seconds to reply to the interaction. If you didn't - discord deletes this interaction, in app you will see "interaction failed" and after you reply code will throw "Unknown interaction" error
To prevent this, you have to defer reply.
What does defer reply do?
Defer reply says discord to wait, it says that you are handling this interaction and know that this interaction exists.
It simply allows you to reply after 15 minutes(you had only 3 seconds before)

#

with this info please send me snippet that will contain defer reply in right position

#

it doesn't shows defer reply
editReply is right for now

#

also, I don't see anything that takes time in your code
what is your ping?

#

what is your ping

#

time between interaction was created and you received this interaction

#

you don't have ping command?

#

yes

#

if you didn't change anything you can face with this error again

#

show code

#

no sense in this lines

#

Hard to read, send it as text or use services like source bin

#

don't override created variable

#

doesn't changes my answer

#

their names are completely same

#

name it differently🤷‍♂️

#

please learn js before trying to create anything with discord.js

#

if you don't know about named variables I can't help you🤷‍♂️

#

Because you edited it?

#

maybe you are updating message

heavy sun
#

I don't get what you meant