kiwiirc / irc-framework

🛠️ A better IRC framework for node.js. For bots and full clients.
MIT License
182 stars 64 forks source link

can't join channel until fully connected (sasl) #348

Open ralyodio opened 1 year ago

ralyodio commented 1 year ago

Is there an event I can listen to like irc.on('connected', ...) ??

dgw commented 1 year ago

How about 'registered'?

https://github.com/kiwiirc/irc-framework/blob/a2697c944efce407a6fd85b876f83907362eead4/examples/bot.js#L51-L53

ralyodio commented 1 year ago

onregistered is when you register a name i think. you only do that once.

dgw commented 1 year ago

The example for 'registered' literally logs "Connected!" and then joins a channel.

A 'registered' event is emitted when irc-framework receives RPL_WELCOME, i.e. the client has finished connecting to the network. Read more about "connection registration" here.