Removed extraneous debug messages. Added a check for UUID.Zero.

0.7.4.1
Diva Canto 2012-03-20 21:36:02 -07:00
parent 7a0d7be44c
commit d49dd5573b
1 changed files with 23 additions and 16 deletions

View File

@ -261,10 +261,10 @@ namespace OpenSim.Region.CoreModules.Avatar.Friends
// fid is not a UUID...
string url = string.Empty, tmp = string.Empty, f = string.Empty, l = string.Empty;
m_log.DebugFormat("[YYY]: FID {0}", fid);
if (Util.ParseUniversalUserIdentifier(fid, out agentID, out url, out f, out l, out tmp))
{
m_log.DebugFormat("[YYY]: Adding user {0} {1} {2}", f, l, url);
if (!agentID.Equals(UUID.Zero))
{
m_uMan.AddUser(agentID, f, l, url);
string name = m_uMan.GetUserName(agentID);
@ -281,6 +281,7 @@ namespace OpenSim.Region.CoreModules.Avatar.Friends
}
return true;
}
}
return false;
}
@ -744,7 +745,13 @@ namespace OpenSim.Region.CoreModules.Avatar.Friends
{
string[] parts = im.fromAgentName.Split(new char[] { '@' });
if (parts.Length == 2)
m_uMan.AddUser(new UUID(im.fromAgentID), parts[0], "http://" + parts[1]);
{
string[] fl = parts[0].Trim().Split(new char[] { '.' });
if (fl.Length == 2)
m_uMan.AddUser(new UUID(im.fromAgentID), fl[0], fl[1], "http://" + parts[1]);
else
m_uMan.AddUser(new UUID(im.fromAgentID), fl[0], "", "http://" + parts[1]);
}
}
return true;
}