aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Data/Null
diff options
context:
space:
mode:
authorDiva Canto2010-04-16 16:36:44 -0700
committerDiva Canto2010-04-16 16:36:44 -0700
commit930d3745256ced37afb2d91817eba941d06a50b0 (patch)
treea39aa45e8291e4ec48efea277c6ec50c5baf70fe /OpenSim/Data/Null
parentrefactor: move DeatchObject() into the AttachmentsModule (diff)
downloadopensim-SC_OLD-930d3745256ced37afb2d91817eba941d06a50b0.zip
opensim-SC_OLD-930d3745256ced37afb2d91817eba941d06a50b0.tar.gz
opensim-SC_OLD-930d3745256ced37afb2d91817eba941d06a50b0.tar.bz2
opensim-SC_OLD-930d3745256ced37afb2d91817eba941d06a50b0.tar.xz
Expose Delete at IUserAccountData interface. It was there already. No changes in IUserAccountService, just the data layer.
Diffstat (limited to 'OpenSim/Data/Null')
-rw-r--r--OpenSim/Data/Null/NullUserAccountData.cs21
1 files changed, 21 insertions, 0 deletions
diff --git a/OpenSim/Data/Null/NullUserAccountData.cs b/OpenSim/Data/Null/NullUserAccountData.cs
index fc2c5d5..9eb94e6 100644
--- a/OpenSim/Data/Null/NullUserAccountData.cs
+++ b/OpenSim/Data/Null/NullUserAccountData.cs
@@ -135,5 +135,26 @@ namespace OpenSim.Data.Null
135 return result; 135 return result;
136 } 136 }
137 137
138 public bool Delete(string field, string val)
139 {
140 // Only delete by PrincipalID
141 if (field.Equals("PrincipalID"))
142 {
143 UUID uuid = UUID.Zero;
144 if (UUID.TryParse(val, out uuid) && m_DataByUUID.ContainsKey(uuid))
145 {
146 UserAccountData account = m_DataByUUID[uuid];
147 m_DataByUUID.Remove(uuid);
148 if (m_DataByName.ContainsKey(account.FirstName + " " + account.LastName))
149 m_DataByName.Remove(account.FirstName + " " + account.LastName);
150 if (account.Data.ContainsKey("Email") && account.Data["Email"] != string.Empty && m_DataByEmail.ContainsKey(account.Data["Email"]))
151 m_DataByEmail.Remove(account.Data["Email"]);
152
153 return true;
154 }
155 }
156
157 return false;
158 }
138 } 159 }
139} 160}