-
-
Notifications
You must be signed in to change notification settings - Fork 4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
ws
throws TypeError: Cannot use 'in' operator to search for 'code' in undefined
when with Deno
#10327
Labels
Comments
NeuroWhAI
changed the title
Jun 6, 2024
ws
throws the error TypeError: Cannot use 'in' operator to search for 'code' in undefined
ws
throws the error TypeError: Cannot use 'in' operator to search for 'code' in undefined
when with Deno
NeuroWhAI
changed the title
Jun 6, 2024
ws
throws the error TypeError: Cannot use 'in' operator to search for 'code' in undefined
when with Denows
throws TypeError: Cannot use 'in' operator to search for 'code' in undefined
when with Deno
Hi. Do you have a full stack trace? I'd like to see what invoked |
I will reproduce and get the trace log. |
Here is a trace log. @didinele
|
If possible, would you be able to log
|
@Jiralite It was connection.onerror = (event) => {
console.log("=======================================");
console.log(JSON.stringify(event));
console.log("=======================================");
this.onError(event.error);
};
|
That's most certainly a deno bug of some sort then, recommend reporting it. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Which package is this bug report for?
ws
Issue description
Error :
TypeError: Cannot use 'in' operator to search for 'code' in undefined
Location: https://github.com/discordjs/discord.js/blob/main/packages/ws/src/ws/WebSocketShard.ts#L794
If I manually modify the conditional statement locally as follows, the problem no longer occurs.
But I'm not sure if it's okay to do this.
I'm not sure if this is due to differences between Deno and Node.js, but I suspect it is.
Code sample
No response
Versions
Issue priority
Low (slightly annoying)
Which partials do you have configured?
No Partials
Which gateway intents are you subscribing to?
Guilds, GuildMessages, MessageContent
I have tested this issue on a development release
No response
The text was updated successfully, but these errors were encountered: