diff options
Diffstat (limited to 'OpenSim/Data/Null')
-rw-r--r-- | OpenSim/Data/Null/NullUserAccountData.cs | 21 |
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 | } |