Rename local variable and remove unused local variable in IrcMessageBuild.cpp

This commit is contained in:
mmb L 2021-11-27 21:51:37 +08:00 committed by pajlada
parent ec966a1791
commit 179527611e

View file

@ -827,18 +827,18 @@ void IrcMessageHandler::handleNoticeMessage(Communi::IrcNoticeMessage *message)
{
return;
}
auto &channelName = hostOn ? parts[2] : parts[0];
if (channelName.size() < 2)
auto &hostedChannelName = hostOn ? parts[2] : parts[0];
if (hostedChannelName.size() < 2)
{
return;
}
if (hostOn)
{
channelName.chop(1);
hostedChannelName.chop(1);
}
MessageBuilder builder;
TwitchMessageBuilder::hostingSystemMessage(channelName, &builder,
hostOn);
TwitchMessageBuilder::hostingSystemMessage(hostedChannelName,
&builder, hostOn);
channel->addMessage(builder.release());
}
else if (tags == "room_mods" || tags == "vips_success")