Error

TypeError: Cannot read private member #clientId from an object whose class did not declare it
at Client.updateVoiceState (Z:\NodeJS\node_modules\moonlink.js\@Moonlink\MoonlinkManager.js:60:29)
at Client.emit (node:events:513:28)
at WebSocketShard.onMessage (Z:\NodeJS\node_modules\discord.js\src\client\websocket\WebSocketShard.js:326:25)
at callListener (Z:\NodeJS\node_modules\ws\lib\event-target.js:290:14)
at WebSocket.onMessage (Z:\NodeJS\node_modules\ws\lib\event-target.js:209:9)
at WebSocket.emit (node:events:513:28)
at Receiver.receiverOnMessage (Z:\NodeJS\node_modules\ws\lib\websocket.js:1178:20)
at Receiver.emit (node:events:513:28)
at Receiver.dataMessage (Z:\NodeJS\node_modules\ws\lib\receiver.js:528:14)
at Receiver.getData (Z:\NodeJS\node_modules\ws\lib\receiver.js:446:17)
TypeError: Cannot read private member #clientId from an object whose class did not declare it
at Client.updateVoiceState (Z:\NodeJS\node_modules\moonlink.js\@Moonlink\MoonlinkManager.js:60:29)
at Client.emit (node:events:513:28)
at WebSocketShard.onMessage (Z:\NodeJS\node_modules\discord.js\src\client\websocket\WebSocketShard.js:326:25)
at callListener (Z:\NodeJS\node_modules\ws\lib\event-target.js:290:14)
at WebSocket.onMessage (Z:\NodeJS\node_modules\ws\lib\event-target.js:209:9)
at WebSocket.emit (node:events:513:28)
at Receiver.receiverOnMessage (Z:\NodeJS\node_modules\ws\lib\websocket.js:1178:20)
at Receiver.emit (node:events:513:28)
at Receiver.dataMessage (Z:\NodeJS\node_modules\ws\lib\receiver.js:528:14)
at Receiver.getData (Z:\NodeJS\node_modules\ws\lib\receiver.js:446:17)
53 Replies
1Lucas1.apk
1Lucas1.apk3y ago
I will fix Is the version updated?
xenial-black
xenial-blackOP3y ago
yes
No description
1Lucas1.apk
1Lucas1.apk3y ago
Did you start the package? <moon>.init(id)
xenial-black
xenial-blackOP3y ago
ofcause
1Lucas1.apk
1Lucas1.apk3y ago
#clientId object is declared in package init
xenial-black
xenial-blackOP3y ago
Private class features - JavaScript | MDN
Class fields are public by default, but private class members can be created by using a hash # prefix. The privacy encapsulation of these class features is enforced by JavaScript itself.
1Lucas1.apk
1Lucas1.apk3y ago
But did you start the package? #clientId; It is undefined above the constructor Its value is changed when package is started
xenial-black
xenial-blackOP3y ago
i started
No description
MEE6
MEE63y ago
GG @Nah, you just advanced to level 1!
xenial-black
xenial-blackOP3y ago
and i can receive the node create event
No description
1Lucas1.apk
1Lucas1.apk3y ago
What version of your node 19?
xenial-black
xenial-blackOP3y ago
v16.17.0
1Lucas1.apk
1Lucas1.apk3y ago
@MOTO
rising-crimson
rising-crimson3y ago
Oq?
1Lucas1.apk
1Lucas1.apk3y ago
Não sei, mais acho que o nodejs mudou a forma das coisas privatizadas
rising-crimson
rising-crimson3y ago
Não
1Lucas1.apk
1Lucas1.apk3y ago
Se coloco static #clientId; Ai aparece que o objeto não existe
rising-crimson
rising-crimson3y ago
Tou usando um monte de classes privadas e não tive q alterar o código
1Lucas1.apk
1Lucas1.apk3y ago
Tou na recente 18
rising-crimson
rising-crimson3y ago
Eu tbm
1Lucas1.apk
1Lucas1.apk3y ago
Também não da erro
rising-crimson
rising-crimson3y ago
Repl não tá aceitando 16
xenial-black
xenial-blackOP3y ago
so i update it to v18.12.1?
No description
rising-crimson
rising-crimson3y ago
>-> deve ser um bug
1Lucas1.apk
1Lucas1.apk3y ago
Test update, because all our projects are working correctly
xenial-black
xenial-blackOP3y ago
👌🏻
rising-crimson
rising-crimson3y ago
Nunca vi esse erro (⁠ ͡⁠°⁠ᴥ⁠ ͡⁠°⁠ ⁠ʋ⁠)
1Lucas1.apk
1Lucas1.apk3y ago
É quando não é encontrado objeto privatizado antes do contrutor
rising-crimson
rising-crimson3y ago
Eu sei Soq nunca vi q eu falei Vou ver os reports
xenial-black
xenial-blackOP3y ago
it still have this error
No description
1Lucas1.apk
1Lucas1.apk3y ago
We are researching this error, we already give a touch
xenial-black
xenial-blackOP3y ago
thx
1Lucas1.apk
1Lucas1.apk3y ago
Do you have access to node_modules? Try putting it in MoonlinkManager.js line 34 this.updateVoiceState.bind(this) .
xenial-black
xenial-blackOP3y ago
No description
MEE6
MEE63y ago
GG @Nah, you just advanced to level 2!
xenial-black
xenial-blackOP3y ago
i found it works
No description
1Lucas1.apk
1Lucas1.apk3y ago
@MOTO
rising-crimson
rising-crimson3y ago
Oi
1Lucas1.apk
1Lucas1.apk3y ago
Vamos ter qu atualizar as classes privadas
rising-crimson
rising-crimson3y ago
Eu não sei mexer em classes privadas Tentei só uma vez
1Lucas1.apk
1Lucas1.apk3y ago
Você vai me ajudar, que a internet aqui do meu tio tá lenta demais
rising-crimson
rising-crimson3y ago
xenial-black
xenial-blackOP3y ago
i just tried to remove # from #clientId and it has no error anymore
1Lucas1.apk
1Lucas1.apk3y ago
update the package and test
xenial-black
xenial-blackOP3y ago
no error more! thx for help
1Lucas1.apk
1Lucas1.apk3y ago
if another error appears, just let me know, I'm in a place where the internet is terrible to do a lot of things Have a great day :)
xenial-black
xenial-blackOP3y ago
you too
rising-crimson
rising-crimson3y ago
If you found bugs, report for us
xenial-black
xenial-blackOP3y ago
Error on @Rest/MakeRequest.js Suggest:
- | 16 | port: url_.port ? url_.port : 443,
+ | 16 | port: url_.port ? url_.port : url_.protocol === 'http:' ? 80 : 443,
- | 16 | port: url_.port ? url_.port : 443,
+ | 16 | port: url_.port ? url_.port : url_.protocol === 'http:' ? 80 : 443,
No description
1Lucas1.apk
1Lucas1.apk3y ago
we will update soon
xenial-black
xenial-blackOP3y ago
thx
1Lucas1.apk
1Lucas1.apk3y ago
New version published Thanks for the suggestion, and have a great day. :)
xenial-black
xenial-blackOP3y ago
you too

Did you find this page helpful?