From 61affee814b6c2a09cb33b1823f009d386f54818 Mon Sep 17 00:00:00 2001
From: Justin Clark-Casey (justincc)
Date: Tue, 13 Sep 2011 22:33:15 +0100
Subject: remove redunant itemID and agentID arguments from UpdateKnownItem().
itemID is always taken taken from the group's stored item id, and agentID is never used.
---
.../Region/CoreModules/Avatar/Attachments/AttachmentsModule.cs | 10 ++++------
1 file changed, 4 insertions(+), 6 deletions(-)
(limited to 'OpenSim/Region/CoreModules/Avatar')
diff --git a/OpenSim/Region/CoreModules/Avatar/Attachments/AttachmentsModule.cs b/OpenSim/Region/CoreModules/Avatar/Attachments/AttachmentsModule.cs
index 03837b5..b9cd880 100644
--- a/OpenSim/Region/CoreModules/Avatar/Attachments/AttachmentsModule.cs
+++ b/OpenSim/Region/CoreModules/Avatar/Attachments/AttachmentsModule.cs
@@ -151,7 +151,7 @@ namespace OpenSim.Region.CoreModules.Avatar.Attachments
// {
grp.IsAttachment = false;
grp.AbsolutePosition = grp.RootPart.AttachedPos;
- UpdateKnownItem(sp.ControllingClient, grp, grp.GetFromItemID(), grp.OwnerID);
+ UpdateKnownItem(sp.ControllingClient, grp);
grp.IsAttachment = true;
// }
}
@@ -668,7 +668,7 @@ namespace OpenSim.Region.CoreModules.Avatar.Attachments
group.IsAttachment = false;
group.AbsolutePosition = group.RootPart.AttachedPos;
- UpdateKnownItem(sp.ControllingClient, group, group.GetFromItemID(), group.OwnerID);
+ UpdateKnownItem(sp.ControllingClient, group);
m_scene.DeleteSceneObject(group, false);
return;
@@ -703,9 +703,7 @@ namespace OpenSim.Region.CoreModules.Avatar.Attachments
///
///
///
- ///
- ///
- private void UpdateKnownItem(IClientAPI remoteClient, SceneObjectGroup grp, UUID itemID, UUID agentID)
+ private void UpdateKnownItem(IClientAPI remoteClient, SceneObjectGroup grp)
{
if (grp.HasGroupChanged || grp.ContainsScripts())
{
@@ -715,7 +713,7 @@ namespace OpenSim.Region.CoreModules.Avatar.Attachments
string sceneObjectXml = SceneObjectSerializer.ToOriginalXmlFormat(grp);
- InventoryItemBase item = new InventoryItemBase(itemID, remoteClient.AgentId);
+ InventoryItemBase item = new InventoryItemBase(grp.GetFromItemID(), remoteClient.AgentId);
item = m_scene.InventoryService.GetItem(item);
if (item != null)
--
cgit v1.1