timotejroiko / discord.js-light

All the power of discord.js, zero caching. This library modifies discord.js's internal classes and functions in order to give you full control over its caching behaviour.
Apache License 2.0
292 stars 29 forks source link

Cannot read properties of undefined (reading '_add') #89

Closed vascobotelho closed 2 years ago

vascobotelho commented 2 years ago

Hi I don't know if this is an issue with discord.js light, but this is coming from there.

TypeError: Cannot read properties of undefined (reading '_add')
    at MessageCreateAction.MessageCreate [as handle] (/app/node_modules/discord.js-light/actions.js:440:36)
    at Object.MESSAGE_CREATE (/app/node_modules/discord.js-light/handlers.js:281:52)
    at WebSocketManager.Client.ws.handlePacket (/app/node_modules/discord.js-light/client.js:47:29)
    at WebSocketShard.onPacket (/app/node_modules/discord.js/src/client/websocket/WebSocketShard.js:444:22)
    at WebSocketShard.onMessage (/app/node_modules/discord.js/src/client/websocket/WebSocketShard.js:301:10)
    at WebSocket.onMessage (/app/node_modules/ws/lib/event-target.js:199:18)
    at WebSocket.emit (node:events:394:28)
    at Receiver.receiverOnMessage (/app/node_modules/ws/lib/websocket.js:1137:20)
    at Receiver.emit (node:events:394:28)
    at Receiver.dataMessage (/app/node_modules/ws/lib/receiver.js:528:14)

versions: discord.js : 13.6.0 discord.js light: 4.6.1

timotejroiko commented 2 years ago

there is a test fix on the v4 branch, can you test it for me? npm i timotejroiko/discord.js-light#v4

vascobotelho commented 2 years ago

I can test it, but I don't know how to reproduce it because this is happening in my production build.

vascobotelho commented 2 years ago

Seems fine to me, I don't have any errors locally.