Commit b13e76b4 authored by Marc Dequènes (Duck)'s avatar Marc Dequènes (Duck)

[fix] don't truncate chat nicks at first space character

parent c69abac4
......@@ -33,8 +33,8 @@ ChatBuddy::ChatBuddy(Server* server, im::ChatBuddy _cbuddy)
string hostname = im_cbuddy.getRealName();
string identname = stringtok(hostname, "@");
string nickname = im_cbuddy.getName();
if(nickname.find('@') != string::npos || nickname.find(' ') != string::npos)
nickname = nickize(stringtok(nickname, " @"));
if(nickname.find('@') != string::npos)
nickname = nickize(stringtok(nickname, "@"));
else
nickname = nickize(nickname);
if(hostname.empty())
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment