mirror of
https://gitlab.com/wirelos/sprocket-plugin-irc.git
synced 2025-12-14 13:41:27 +01:00
publish connected state
This commit is contained in:
@@ -62,10 +62,12 @@ void IrcPlugin::connect()
|
|||||||
if (client->connect(nick.c_str(), user.c_str()))
|
if (client->connect(nick.c_str(), user.c_str()))
|
||||||
{
|
{
|
||||||
PRINT_MSG(Serial, "IRC", "connected");
|
PRINT_MSG(Serial, "IRC", "connected");
|
||||||
|
publish("irc/connected", "1");
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
PRINT_MSG(Serial, "IRC", "failed... ");
|
PRINT_MSG(Serial, "IRC", "failed... ");
|
||||||
|
publish("irc/connected", "0");
|
||||||
}
|
}
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user