From 4083e972ccf238cd02d60da2af88855f25ed7b1f Mon Sep 17 00:00:00 2001 From: Merov Linden Date: Mon, 9 Jun 2014 15:20:07 -0700 Subject: DD-97 : When clearing the version folder of a record, force activation (listed) status to false at the same time, avoiding confusing (and eventually wrong) double call to updateSLMListing --- indra/newview/llinventoryfunctions.cpp | 1 - indra/newview/llmarketplacefunctions.cpp | 3 ++- 2 files changed, 2 insertions(+), 2 deletions(-) (limited to 'indra/newview') diff --git a/indra/newview/llinventoryfunctions.cpp b/indra/newview/llinventoryfunctions.cpp index b17e9551e5..606f95560b 100755 --- a/indra/newview/llinventoryfunctions.cpp +++ b/indra/newview/llinventoryfunctions.cpp @@ -167,7 +167,6 @@ void update_marketplace_category(const LLUUID& cur_uuid, bool perform_consistenc { LL_INFOS("SLM") << "Unlist as the version folder is not under the listing folder anymore!!" << LL_ENDL; LLMarketplaceData::instance().setVersionFolder(listing_uuid, LLUUID::null); - LLMarketplaceData::instance().activateListing(listing_uuid, false); } } diff --git a/indra/newview/llmarketplacefunctions.cpp b/indra/newview/llmarketplacefunctions.cpp index d8f78ce81a..3b68c12d11 100755 --- a/indra/newview/llmarketplacefunctions.cpp +++ b/indra/newview/llmarketplacefunctions.cpp @@ -1285,7 +1285,8 @@ bool LLMarketplaceData::setVersionFolder(const LLUUID& folder_id, const LLUUID& return false; } - bool is_listed = getActivationState(listing_uuid); + // Note: if the version_id is cleared, we need to unlist the listing, otherwise, state unchanged + bool is_listed = (version_id.isNull() ? false : getActivationState(listing_uuid)); // Post the listing update request to SLM updateSLMListing(listing_uuid, listing_id, version_id, is_listed); -- cgit v1.2.3