aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Data/Null/NullFriendsData.cs
diff options
context:
space:
mode:
authorMelanie2011-06-09 02:05:04 +0100
committerMelanie2011-06-09 02:05:04 +0100
commit326c46ba70cea70ddfe4aef9a6b73edff63e126a (patch)
tree5e76347b0d77f58717d8e5e4f3b8787ff01a18d7 /OpenSim/Data/Null/NullFriendsData.cs
parentMake the last otem in a list created with llCSV2List findable (diff)
parentConsistency fix on the last commit. (diff)
downloadopensim-SC-326c46ba70cea70ddfe4aef9a6b73edff63e126a.zip
opensim-SC-326c46ba70cea70ddfe4aef9a6b73edff63e126a.tar.gz
opensim-SC-326c46ba70cea70ddfe4aef9a6b73edff63e126a.tar.bz2
opensim-SC-326c46ba70cea70ddfe4aef9a6b73edff63e126a.tar.xz
Merge branch 'master' into careminster-presence-refactor
Diffstat (limited to '')
-rw-r--r--OpenSim/Data/Null/NullFriendsData.cs18
1 files changed, 14 insertions, 4 deletions
diff --git a/OpenSim/Data/Null/NullFriendsData.cs b/OpenSim/Data/Null/NullFriendsData.cs
index e7f7fd3..d90788a 100644
--- a/OpenSim/Data/Null/NullFriendsData.cs
+++ b/OpenSim/Data/Null/NullFriendsData.cs
@@ -42,6 +42,11 @@ namespace OpenSim.Data.Null
42 { 42 {
43 } 43 }
44 44
45 public FriendsData[] GetFriends(UUID principalID)
46 {
47 return GetFriends(principalID.ToString());
48 }
49
45 /// <summary> 50 /// <summary>
46 /// Tries to implement the Get [] semantics, but it cuts corners. 51 /// Tries to implement the Get [] semantics, but it cuts corners.
47 /// Specifically, it gets all friendships even if they weren't accepted yet. 52 /// Specifically, it gets all friendships even if they weren't accepted yet.
@@ -49,11 +54,11 @@ namespace OpenSim.Data.Null
49 /// <param name="fields"></param> 54 /// <param name="fields"></param>
50 /// <param name="values"></param> 55 /// <param name="values"></param>
51 /// <returns></returns> 56 /// <returns></returns>
52 public FriendsData[] GetFriends(UUID userID) 57 public FriendsData[] GetFriends(string userID)
53 { 58 {
54 List<FriendsData> lst = m_Data.FindAll(delegate (FriendsData fdata) 59 List<FriendsData> lst = m_Data.FindAll(delegate (FriendsData fdata)
55 { 60 {
56 return fdata.PrincipalID == userID; 61 return fdata.PrincipalID == userID.ToString();
57 }); 62 });
58 63
59 if (lst != null) 64 if (lst != null)
@@ -72,9 +77,14 @@ namespace OpenSim.Data.Null
72 return true; 77 return true;
73 } 78 }
74 79
75 public bool Delete(UUID userID, string friendID) 80 public bool Delete(UUID principalID, string friend)
81 {
82 return Delete(principalID.ToString(), friend);
83 }
84
85 public bool Delete(string userID, string friendID)
76 { 86 {
77 List<FriendsData> lst = m_Data.FindAll(delegate(FriendsData fdata) { return fdata.PrincipalID == userID; }); 87 List<FriendsData> lst = m_Data.FindAll(delegate(FriendsData fdata) { return fdata.PrincipalID == userID.ToString(); });
78 if (lst != null) 88 if (lst != null)
79 { 89 {
80 FriendsData friend = lst.Find(delegate(FriendsData fdata) { return fdata.Friend == friendID; }); 90 FriendsData friend = lst.Find(delegate(FriendsData fdata) { return fdata.Friend == friendID; });