diff --git a/OpenSim/Data/MySQL/MySQLUserProfilesData.cs b/OpenSim/Data/MySQL/MySQLUserProfilesData.cs index e301bbe130..adb75d63dc 100644 --- a/OpenSim/Data/MySQL/MySQLUserProfilesData.cs +++ b/OpenSim/Data/MySQL/MySQLUserProfilesData.cs @@ -250,7 +250,7 @@ namespace OpenSim.Data.MySQL string query = string.Empty; query += "DELETE FROM classifieds WHERE "; - query += "classifieduuid = ?ClasifiedId"; + query += "classifieduuid = ?recordId"; try { @@ -260,12 +260,8 @@ namespace OpenSim.Data.MySQL using (MySqlCommand cmd = new MySqlCommand(query, dbcon)) { - cmd.Parameters.AddWithValue("?ClassifiedId", recordId.ToString()); - - lock(Lock) - { - cmd.ExecuteNonQuery(); - } + cmd.Parameters.AddWithValue("?recordId", recordId.ToString()); + cmd.ExecuteNonQuery(); } } } diff --git a/OpenSim/Server/Handlers/Profiles/UserProfilesHandlers.cs b/OpenSim/Server/Handlers/Profiles/UserProfilesHandlers.cs index d55142efc6..6721b08025 100644 --- a/OpenSim/Server/Handlers/Profiles/UserProfilesHandlers.cs +++ b/OpenSim/Server/Handlers/Profiles/UserProfilesHandlers.cs @@ -126,14 +126,14 @@ namespace OpenSim.Server.Handlers } OSDMap request = (OSDMap)json["params"]; - UUID classifiedId = new UUID(request["classifiedID"].AsString()); - - OSDMap res = new OSDMap(); - res["result"] = OSD.FromString("success"); - response.Result = res; - - return true; + UUID classifiedId = new UUID(request["classifiedId"].AsString()); + if(Service.ClassifiedDelete(classifiedId)) + return true; + + response.Error.Code = ErrorCode.InternalError; + response.Error.Message = "data error removing record"; + return false; } public bool ClassifiedInfoRequest(OSDMap json, ref JsonRpcResponse response)