@@ -90,13 +90,6 @@ void TwitchServer::initializeConnection(IrcConnection *connection, bool isRead,
|
||||
connection->setPassword(oauthToken);
|
||||
}
|
||||
|
||||
connection->sendCommand(
|
||||
Communi::IrcCommand::createCapability("REQ", "twitch.tv/membership"));
|
||||
connection->sendCommand(
|
||||
Communi::IrcCommand::createCapability("REQ", "twitch.tv/commands"));
|
||||
connection->sendCommand(
|
||||
Communi::IrcCommand::createCapability("REQ", "twitch.tv/tags"));
|
||||
|
||||
connection->setSecure(true);
|
||||
|
||||
// https://dev.twitch.tv/docs/irc/guide/#connecting-to-twitch-irc
|
||||
@@ -206,6 +199,13 @@ void TwitchServer::writeConnectionMessageReceived(Communi::IrcMessage *message)
|
||||
}
|
||||
}
|
||||
|
||||
void TwitchServer::onConnected(IrcConnection *connection)
|
||||
{
|
||||
// connection in thise case is the read connection
|
||||
connection->sendRaw(
|
||||
"CAP REQ :twitch.tv/tags twitch.tv/commands twitch.tv/membership");
|
||||
}
|
||||
|
||||
std::shared_ptr<Channel> TwitchServer::getCustomChannel(
|
||||
const QString &channelName)
|
||||
{
|
||||
|
||||
@@ -55,6 +55,8 @@ protected:
|
||||
virtual void writeConnectionMessageReceived(
|
||||
Communi::IrcMessage *message) override;
|
||||
|
||||
virtual void onConnected(IrcConnection *connection) override;
|
||||
|
||||
virtual std::shared_ptr<Channel> getCustomChannel(
|
||||
const QString &channelname) override;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user