From b41ebb7bea9a30d5824c8adc7c86d7d270b2b72d Mon Sep 17 00:00:00 2001
From: maxim_productengine <mnikolenko@productengine.com>
Date: Wed, 8 May 2019 17:33:52 +0300
Subject: [PATCH] SL-1579 Don't put an object to 'Received Items' after taking
 it back into inventory

---
 indra/newview/llviewermenu.cpp | 6 ++++++
 1 file changed, 6 insertions(+)

diff --git a/indra/newview/llviewermenu.cpp b/indra/newview/llviewermenu.cpp
index 2b9f0f642ea..52b2c631fa4 100644
--- a/indra/newview/llviewermenu.cpp
+++ b/indra/newview/llviewermenu.cpp
@@ -4751,6 +4751,12 @@ void handle_take()
 				category_id.setNull();
 			}
 
+			// check inbox
+			const LLUUID inbox_id = gInventory.findCategoryUUIDForType(LLFolderType::FT_INBOX);
+			if (category_id == inbox_id || gInventory.isObjectDescendentOf(category_id, inbox_id))
+			{
+				category_id.setNull();
+			}
 		}
 	}
 	if(category_id.isNull())
-- 
GitLab