* Cleaned up and commented the messy SendInventoryUpdate, fixed a broken debug line, and commented the debug line out since it can quickly become noisy

slimupdates
John Hurliman 2010-03-10 14:05:49 -08:00
parent 4b8af2e1aa
commit 2af97b46ec
1 changed files with 10 additions and 10 deletions

View File

@ -1102,18 +1102,18 @@ namespace OpenSim.Region.Framework.Scenes
if (folder == null)
return;
m_log.DebugFormat("[AGENT INVENTORY]: Send Inventory Folder {0} Update to {1} {2}", folder.Name, client.FirstName, client.LastName);
// Fetch the folder contents
InventoryCollection contents = InventoryService.GetFolderContent(client.AgentId, folder.ID);
InventoryFolderBase containingFolder = new InventoryFolderBase();
containingFolder.ID = folder.ID;
containingFolder.Owner = client.AgentId;
containingFolder = InventoryService.GetFolder(containingFolder);
if (containingFolder != null)
{
int version = containingFolder.Version;
client.SendInventoryFolderDetails(client.AgentId, folder.ID, contents.Items, contents.Folders, version, fetchFolders, fetchItems);
}
// Fetch the folder itself to get its current version
InventoryFolderBase containingFolder = new InventoryFolderBase(folder.ID, client.AgentId);
containingFolder = InventoryService.GetFolder(containingFolder);
//m_log.DebugFormat("[AGENT INVENTORY]: Sending inventory folder contents ({0} nodes) for \"{1}\" to {2} {3}",
// contents.Folders.Count + contents.Items.Count, containingFolder.Name, client.FirstName, client.LastName);
if (containingFolder != null)
client.SendInventoryFolderDetails(client.AgentId, folder.ID, contents.Items, contents.Folders, containingFolder.Version, fetchFolders, fetchItems);
}
/// <summary>