diff options
Diffstat (limited to 'OpenSim/Region/Framework/Scenes')
-rw-r--r-- | OpenSim/Region/Framework/Scenes/SceneObjectPartInventory.cs | 22 |
1 files changed, 14 insertions, 8 deletions
diff --git a/OpenSim/Region/Framework/Scenes/SceneObjectPartInventory.cs b/OpenSim/Region/Framework/Scenes/SceneObjectPartInventory.cs index aaf9ffa..8810903 100644 --- a/OpenSim/Region/Framework/Scenes/SceneObjectPartInventory.cs +++ b/OpenSim/Region/Framework/Scenes/SceneObjectPartInventory.cs | |||
@@ -582,14 +582,20 @@ namespace OpenSim.Region.Framework.Scenes | |||
582 | return item; | 582 | return item; |
583 | } | 583 | } |
584 | 584 | ||
585 | /// <summary> | 585 | public TaskInventoryItem GetInventoryItem(string name) |
586 | /// Get inventory items by name. | 586 | { |
587 | /// </summary> | 587 | lock (m_items) |
588 | /// <param name="name"></param> | 588 | { |
589 | /// <returns> | 589 | foreach (TaskInventoryItem item in m_items.Values) |
590 | /// A list of inventory items with that name. | 590 | { |
591 | /// If no inventory item has that name then an empty list is returned. | 591 | if (item.Name == name) |
592 | /// </returns> | 592 | return item; |
593 | } | ||
594 | } | ||
595 | |||
596 | return null; | ||
597 | } | ||
598 | |||
593 | public List<TaskInventoryItem> GetInventoryItems(string name) | 599 | public List<TaskInventoryItem> GetInventoryItems(string name) |
594 | { | 600 | { |
595 | List<TaskInventoryItem> items = new List<TaskInventoryItem>(); | 601 | List<TaskInventoryItem> items = new List<TaskInventoryItem>(); |