diff --git a/OpenSim/Region/CoreModules/Framework/InventoryAccess/HGInventoryAccessModule.cs b/OpenSim/Region/CoreModules/Framework/InventoryAccess/HGInventoryAccessModule.cs index 6b78fe8c18..96e043ecfb 100644 --- a/OpenSim/Region/CoreModules/Framework/InventoryAccess/HGInventoryAccessModule.cs +++ b/OpenSim/Region/CoreModules/Framework/InventoryAccess/HGInventoryAccessModule.cs @@ -209,7 +209,14 @@ namespace OpenSim.Region.CoreModules.Framework.InventoryAccess } } - public void PostInventoryAsset(InventoryItemBase item, int userlevel) + private void PostInventoryAsset(InventoryItemBase item, int userlevel) + { + InventoryFolderBase f = m_Scene.InventoryService.GetFolderForType(item.Owner, FolderType.Trash); + if (f == null || (f != null && item.Folder != f.ID)) + PostInventoryAsset(item.Owner, (AssetType)item.AssetType, item.AssetID, item.Name, userlevel); + } + + private void PostInventoryAsset(UUID avatarID, AssetType type, UUID assetID, string name, int userlevel) { if (item.AssetType == (int)AssetType.Link) return; diff --git a/OpenSim/Region/CoreModules/Framework/InventoryAccess/InventoryAccessModule.cs b/OpenSim/Region/CoreModules/Framework/InventoryAccess/InventoryAccessModule.cs index ba8b1ee0f1..64233d5be0 100644 --- a/OpenSim/Region/CoreModules/Framework/InventoryAccess/InventoryAccessModule.cs +++ b/OpenSim/Region/CoreModules/Framework/InventoryAccess/InventoryAccessModule.cs @@ -566,7 +566,7 @@ namespace OpenSim.Region.CoreModules.Framework.InventoryAccess } // This is a hook to do some per-asset post-processing for subclasses that need that - if (remoteClient != null) + if (remoteClient != null && action != DeRezAction.Delete) ExportAsset(remoteClient.AgentId, asset.FullID); return item;