mirror of
https://github.com/znc/znc.git
synced 2026-03-28 17:42:41 +01:00
CMessage::SetParams(): forget the colon
1a3e9ec made CMessage try to retain the colon if the original message
contained one. We should not, however, remember that when the params
are replaced entirely. Consider for example an extended-join message
that is made suitable for a client that doesn't have extended-join
capability:
CMessage msg(":nick!ident@host JOIN #chan account :real name");
msg.SetParams({msg.GetParam(0)});
msg.ToString(); // ":nick!ident@host JOIN :#chan"
This commit is contained in:
@@ -65,6 +65,7 @@ CString CMessage::GetParams(unsigned int uIdx, unsigned int uLen) const
|
||||
void CMessage::SetParams(const VCString& vsParams)
|
||||
{
|
||||
m_vsParams = vsParams;
|
||||
m_bColon = false;
|
||||
|
||||
if (m_eType == Type::Text || m_eType == Type::Notice || m_eType == Type::Action || m_eType == Type::CTCP) {
|
||||
InitType();
|
||||
|
||||
Reference in New Issue
Block a user