GetProductInfo() should still return Description even when field empty

In my opinion, MarketplaceService:GetProductInfo() should still return the Description of an item as just an empty string ("") instead of being nil

local BoostData = MarketplaceService:GetProductInfo(boost.Id, Enum.InfoType.Product)

print(BoostData.Description) -- prints nil

It would be an improvement as it wouldn’t error.

6 Likes

Did you miss the second half of your post? You haven’t explained at all how this would be an improvement.

oh sorry, the deed has been done

It doesn’t error – it returns nil. Are you trying to say you can’t easily concatenate it into a string since you need to do a check first and replace it with an empty string yourself before you can actually use it inside other strings / string properties?

If I do Label.Text = BoostData.Description, it errors

If a description is empty, you would be able to tell and work with it in code in a way that makes sense i.e

if BoostData.Description then
Label.Text = BoostData.Description
else
Label.Text = “No Description Available.”
end

Making this change would break a significant amount of experiences for this reason as well.

Written on phone sorry if any errors

4 Likes