From 1f04e1bc23b0fc7a27ee9d14b830b1e5e08c01c4 Mon Sep 17 00:00:00 2001 From: Justin Clark-Casey (justincc) Date: Sat, 17 Jan 2015 00:08:16 +0000 Subject: minor: In AttachmentsModule.UpdateKnownItem use the existing IInventoryAccessModule reference that other methods are already using rather than fetching its own copy. --- OpenSim/Region/CoreModules/Avatar/Attachments/AttachmentsModule.cs | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) (limited to 'OpenSim/Region/CoreModules/Avatar/Attachments') diff --git a/OpenSim/Region/CoreModules/Avatar/Attachments/AttachmentsModule.cs b/OpenSim/Region/CoreModules/Avatar/Attachments/AttachmentsModule.cs index 4af4ddb..8705dd5 100644 --- a/OpenSim/Region/CoreModules/Avatar/Attachments/AttachmentsModule.cs +++ b/OpenSim/Region/CoreModules/Avatar/Attachments/AttachmentsModule.cs @@ -795,9 +795,8 @@ namespace OpenSim.Region.CoreModules.Avatar.Attachments Utils.StringToBytes(sceneObjectXml), sp.UUID); - IInventoryAccessModule invAccess = m_scene.RequestModuleInterface(); - - invAccess.UpdateInventoryItemAsset(sp.UUID, item, asset); + if (m_invAccessModule != null) + m_invAccessModule.UpdateInventoryItemAsset(sp.UUID, item, asset); // If the name of the object has been changed whilst attached then we want to update the inventory // item in the viewer. -- cgit v1.1