aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim
diff options
context:
space:
mode:
authorDiva Canto2010-02-27 11:23:31 -0800
committerDiva Canto2010-02-27 11:23:31 -0800
commit593fd54fc77bc712d89b8b95c2813491419fc6aa (patch)
treeff723ef154949a7c6a4a63df20a668d8cd4b074b /OpenSim
parent* Finished implementation of FriendsService.Delete (diff)
downloadopensim-SC_OLD-593fd54fc77bc712d89b8b95c2813491419fc6aa.zip
opensim-SC_OLD-593fd54fc77bc712d89b8b95c2813491419fc6aa.tar.gz
opensim-SC_OLD-593fd54fc77bc712d89b8b95c2813491419fc6aa.tar.bz2
opensim-SC_OLD-593fd54fc77bc712d89b8b95c2813491419fc6aa.tar.xz
Update the local cache upon friendship acceptance. Logout notifications working.
Diffstat (limited to 'OpenSim')
-rw-r--r--OpenSim/Region/CoreModules/Avatar/Friends/FriendsModule.cs4
1 files changed, 4 insertions, 0 deletions
diff --git a/OpenSim/Region/CoreModules/Avatar/Friends/FriendsModule.cs b/OpenSim/Region/CoreModules/Avatar/Friends/FriendsModule.cs
index 8f1b5d7..a750c92 100644
--- a/OpenSim/Region/CoreModules/Avatar/Friends/FriendsModule.cs
+++ b/OpenSim/Region/CoreModules/Avatar/Friends/FriendsModule.cs
@@ -419,6 +419,8 @@ namespace OpenSim.Region.CoreModules.Avatar.Friends
419 private void OnApproveFriendRequest(IClientAPI client, UUID agentID, UUID friendID, List<UUID> callingCardFolders) 419 private void OnApproveFriendRequest(IClientAPI client, UUID agentID, UUID friendID, List<UUID> callingCardFolders)
420 { 420 {
421 FriendsService.StoreFriend(agentID, friendID.ToString(), 1); 421 FriendsService.StoreFriend(agentID, friendID.ToString(), 1);
422 // update the local cache
423 m_Friends[agentID].Friends = FriendsService.GetFriends(agentID);
422 424
423 m_log.DebugFormat("[FRIENDS]: {0} accepted friendship from {1}", agentID, friendID); 425 m_log.DebugFormat("[FRIENDS]: {0} accepted friendship from {1}", agentID, friendID);
424 426
@@ -434,6 +436,8 @@ namespace OpenSim.Region.CoreModules.Avatar.Friends
434 (byte)OpenMetaverse.InstantMessageDialog.FriendshipAccepted, client.AgentId.ToString(), false, Vector3.Zero); 436 (byte)OpenMetaverse.InstantMessageDialog.FriendshipAccepted, client.AgentId.ToString(), false, Vector3.Zero);
435 friendClient.SendInstantMessage(im); 437 friendClient.SendInstantMessage(im);
436 client.SendAgentOnline(new UUID[] { friendID }); 438 client.SendAgentOnline(new UUID[] { friendID });
439 // update the local cache
440 m_Friends[friendID].Friends = FriendsService.GetFriends(friendID);
437 // we're done 441 // we're done
438 return; 442 return;
439 } 443 }