#Webhook Error

22 messages · Page 1 of 1 (latest)

gusty patioBOT
#
  • Consider reading #how-to-get-help to improve your question!
  • Explain what exactly your issue is.
  • Post the full error stack trace, not just the top part!
  • Show your code!
  • Issue solved? Press the button!
arctic citrus
#

Show the full error including stacktrace

near urchin
#

Can I ask what your node and djs version is?

#

Actually looking at the code I’m guessing you passed something funky into the files property

muted cobalt
muted cobalt
#

I am using webhookClient.send() to send :

  • username
  • avatarURL
  • embeds
  • files
  • components
#

Files and embed keep changing, others are static

arctic citrus
#

It appears you pass something that is neither a string nor a Buffer nor a Stream nor an Attachment as one of the files so resolveFile gets called with undefined

muted cobalt
arctic citrus
#

Show the code how you create it and pass it

near urchin
#

You should do what Qjuh said and show the entire code. Also, is it not toBuffer rather then encode? Never seen encode before

muted cobalt
#

I believe toBuffer used to give me errors

sage depot
#

show the parts that are relevant

empty prairieBOT
#

To share long code snippets, use a service like gist, sourcebin, pastebin, or similar instead of posting them as large code blocks or files.

near urchin
#

And the part where you send everything?

muted cobalt
#

Looks like they create a new url x)

near urchin
#

My best guess is one of the images is undefined. But I’m sure one of the others in this thread may know more

arctic citrus
#

Show how those two methods get called (and how the result of the first one ends up in the call of the second one)