Guard against inventory get failures.
parent
772aedc731
commit
87d810217e
|
@ -859,6 +859,9 @@ namespace OpenSim.Region.CoreModules.Avatar.Attachments
|
||||||
|
|
||||||
InventoryItemBase item = new InventoryItemBase(itemID, sp.UUID);
|
InventoryItemBase item = new InventoryItemBase(itemID, sp.UUID);
|
||||||
item = m_scene.InventoryService.GetItem(item);
|
item = m_scene.InventoryService.GetItem(item);
|
||||||
|
if (item == null)
|
||||||
|
return;
|
||||||
|
|
||||||
bool changed = sp.Appearance.SetAttachment((int)AttachmentPt, itemID, item.AssetID);
|
bool changed = sp.Appearance.SetAttachment((int)AttachmentPt, itemID, item.AssetID);
|
||||||
if (changed && m_scene.AvatarFactory != null)
|
if (changed && m_scene.AvatarFactory != null)
|
||||||
{
|
{
|
||||||
|
|
Loading…
Reference in New Issue