Added a message when an invalid /delete appears

This commit is contained in:
apa420 2019-04-28 11:31:34 +02:00
parent 3c1d264689
commit ae0122e389

View file

@ -552,7 +552,17 @@ void IrcMessageHandler::handleNoticeMessage(Communi::IrcNoticeMessage *message)
return; return;
} }
channel->addMessage(msg); QString tags = message->tags().value("msg-id", "").toString();
if (tags == "bad_delete_message_error" || tags == "usage_delete")
{
channel->addMessage(makeSystemMessage(
"Usage: \"/delete <msg-id>\" - can't take more "
"than one argument"));
}
else
{
channel->addMessage(msg);
}
} }
} }