FIRE-33368: Fix crash when trying to save material as...

meow-7.2.2
Ansariel 2023-12-04 16:23:40 +01:00
parent 2fc942a75c
commit 9a03bcef79
1 changed files with 15 additions and 4 deletions

View File

@ -127,10 +127,21 @@ const LLInventoryItem *LLPreview::getItem() const
else if (mObjectUUID.isNull())
{
// [SL:KB] - Patch: UI-Notecards | Checked: 2010-09-11 (Catznip-2.1.2d) | Added: Catznip-2.1.2d
if (LLInventoryType::IT_NONE == mAuxItem->getInventoryType() && mItemUUID.notNull())
item = gInventory.getItem(mItemUUID);
else if (!mIsMaterialPreview) // <FS:Ansariel> FIRE-33196: Fix materials upload conflicting with embedded items in notecards fix
item = mAuxItem;
if (mIsMaterialPreview)
{
if (mItemUUID.notNull())
{
// it's an inventory item, so get the item.
item = gInventory.getItem(mItemUUID);
}
}
else
{
if (LLInventoryType::IT_NONE == mAuxItem->getInventoryType())
item = gInventory.getItem(mItemUUID);
else
item = mAuxItem;
}
// [/SL:KB]
//if (mItemUUID.notNull())
//{