Type: Functional
Severity: Minor
Version: 10.2.5.53584
Problem
C_Item.GetIemLocation() returns invalid itemLocations when given an item GUID for a bank bag slot. Crucially it will be missing its equipment slot, and using it with functions that take an itemLocation as an argument will result in an argument error.
Reproduction steps
Enter /run TooltipDataProcessor.AddTooltipPostCall(Enum.TooltipDataType.Item,function (t,d) l=C_Item.GetItemLocation(d.guid);print(l:HasAnyLocation(),l:IsEquipmentSlot(),(select(2,pcall(ItemLocationMixin.IsValid,l))));end) in chat
Mouseover a bag in any of your bag bank slots
Expected result
Prints true true true.
Actual result
Prints false false Interface/FrameXML/ObjectAPI/ItemLocation.lua69: bad argument #1 to 'DoesItemExist' (Usage: local itemExists = C_Item.DoesItemExist(emptiableItemLocation)).
Type: Functional Severity: Minor Version: 10.2.5.53584
Problem
C_Item.GetIemLocation()
returns invaliditemLocation
s when given an item GUID for a bank bag slot. Crucially it will be missing its equipment slot, and using it with functions that take anitemLocation
as an argument will result in an argument error.Reproduction steps
/run TooltipDataProcessor.AddTooltipPostCall(Enum.TooltipDataType.Item,function (t,d) l=C_Item.GetItemLocation(d.guid);print(l:HasAnyLocation(),l:IsEquipmentSlot(),(select(2,pcall(ItemLocationMixin.IsValid,l))));end)
in chatExpected result
Prints
true true true
.Actual result
Prints
false false Interface/FrameXML/ObjectAPI/ItemLocation.lua69: bad argument #1 to 'DoesItemExist' (Usage: local itemExists = C_Item.DoesItemExist(emptiableItemLocation))
.