Dialogue UI

Dialogue UI

647k Downloads

Error when interacting with NPC offering quest with currency rewards: attempt to index local 'currencyID' (a number value)

krohrbaugh opened this issue ยท 1 comments

commented

Add-on version 0.3.6 is failing when interacting with some NPCs offering quests as of July 30, 2024 patch (v11.0.0.55846) with the following error. When this occurs, no dialogue is shown.

The referenced line was added in v0.3.6, but it seems like it should instead be

return currencyInfo and currencyInfo.quantity or 0

I have confirmed that changing DialogueUI/API.lua:1316 to the above resolved the issue on my local installation.


Full error follows:

Message: Interface/AddOns/DialogueUI/API.lua:1316: attempt to index local 'currencyID' (a number value)
Time: Tue Jul 30 15:25:36 2024
Count: 1
Stack: Interface/AddOns/DialogueUI/API.lua:1316: attempt to index local 'currencyID' (a number value)
[string "@Interface/AddOns/DialogueUI/API.lua"]:1316: in function `GetOwnedCurrencyQuantity'
[string "@Interface/AddOns/DialogueUI/Code/SharedUITemplates.lua"]:1632: in function `SetCurrency'
[string "@Interface/AddOns/DialogueUI/Code/SharedUITemplates.lua"]:1660: in function `?'
[string "@Interface/AddOns/DialogueUI/Code/UI.lua"]:2603: in function `FormatRewards'
[string "@Interface/AddOns/DialogueUI/Code/UI.lua"]:1485: in function `?'
[string "@Interface/AddOns/DialogueUI/Code/UI.lua"]:1979: in function `ShowUI'
[string "@Interface/AddOns/DialogueUI/Code/Core.lua"]:117: in function <Interface/AddOns/DialogueUI/Code/Core.lua:80>

Locals: currencyID = 2003
currencyInfo = <table> {
 canEarnPerWeek = false
 description = "Various resources and building materials that can assist the friendly factions of the Dragon Isles in their fight against the Primalists. Used to purchase items unlocked from renown."
 isShowInBackpack = false
 isAccountTransferable = true
 iconFileID = 2065578
 isHeader = false
 isTypeUnused = false
 discovered = true
 currencyListDepth = 0
 rechargingAmountPerCycle = 0
 rechargingCycleDurationMS = 0
 transferPercentage = 100
 quantityEarnedThisWeek = 0
 isHeaderExpanded = false
 isTradeable = false
 quality = 1
 currencyID = 2003
 totalEarned = 0
 quantity = 1416
 name = "Dragon Isles Supplies"
 maxWeeklyQuantity = 0
 useTotalEarnedForMaxQty = false
 isAccountWide = false
 maxQuantity = 0
 trackedQuantity = 0
}
(*temporary) = <table> {
 canEarnPerWeek = false
 description = "Various resources and building materials that can assist the friendly factions of the Dragon Isles in their fight against the Primalists. Used to purchase items unlocked from renown."
 isShowInBackpack = false
 isAccountTransferable = true
 iconFileID = 2065578
 isHeader = false
 isTypeUnused = false
 discovered = true
 currencyListDepth = 0
 rechargingAmountPerCycle = 0
 rechargingCycleDurationMS = 0
 transferPercentage = 100
 quantityEarnedThisWeek = 0
 isHeaderExpanded = false
 isTradeable = false
 quality = 1
 currencyID = 2003
 totalEarned = 0
 quantity = 1416
 name = "Dragon Isles Supplies"
 maxWeeklyQuantity = 0
 useTotalEarnedForMaxQty = false
 isAccountWide = false
 maxQuantity = 0
 trackedQuantity = 0
}
(*temporary) = "attempt to index local 'currencyID' (a number value)"
commented

It's done! Thanks for pointing it out.