mirror of
https://github.com/opensim/opensim.git
synced 2026-08-11 20:05:33 +08:00
Bug fix: wrong name of requester in local friendship offer.
This commit is contained in:
@@ -503,7 +503,7 @@ namespace OpenSim.Region.CoreModules.Avatar.Friends
|
|||||||
UUID principalID = new UUID(im.fromAgentID);
|
UUID principalID = new UUID(im.fromAgentID);
|
||||||
UUID friendID = new UUID(im.toAgentID);
|
UUID friendID = new UUID(im.toAgentID);
|
||||||
|
|
||||||
m_log.DebugFormat("[FRIENDS]: {0} offered friendship to {1}", principalID, friendID);
|
m_log.DebugFormat("[FRIENDS]: {0} ({1}) offered friendship to {2}", principalID, im.fromAgentName, friendID);
|
||||||
|
|
||||||
// This user wants to be friends with the other user.
|
// This user wants to be friends with the other user.
|
||||||
// Let's add the relation backwards, in case the other is not online
|
// Let's add the relation backwards, in case the other is not online
|
||||||
@@ -521,6 +521,9 @@ namespace OpenSim.Region.CoreModules.Avatar.Friends
|
|||||||
im.imSessionID = im.fromAgentID;
|
im.imSessionID = im.fromAgentID;
|
||||||
|
|
||||||
// Try the local sim
|
// Try the local sim
|
||||||
|
UserAccount account = UserAccountService.GetUserAccount(Scene.RegionInfo.ScopeID, agentID);
|
||||||
|
im.fromAgentName = (account == null) ? "Unknown" : account.FirstName + " " + account.LastName;
|
||||||
|
|
||||||
if (LocalFriendshipOffered(friendID, im))
|
if (LocalFriendshipOffered(friendID, im))
|
||||||
return;
|
return;
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user