Questie is deleting the global error() function!
ssateneth opened this issue ยท 3 comments
Bug description
After a few seconds from loading UI, the error() function gets nil'd out. This is BAD and breaks a number of other addons I use that also use the error() function.
Screenshots
Questie version
4.1.1 dev version edd4de0
seems your error has something to do with lines 1246 and 1257 in modules\questietracker.lua. you didn't localize them, they are global!
if Questie.db.char.TrackerLocation then
-- we need to pcall this because it can error if something like MoveAnything is used to move the tracker
result, error = pcall(frm.SetPoint, frm, unpack(Questie.db.char.TrackerLocation))
if not result then
Questie.db.char.TrackerLocation = nil
print(QuestieLocale:GetUIString('TRACKER_INVALID_LOCATION'))
result, error = pcall(frm.SetPoint, frm, unpack({QuestWatchFrame:GetPoint()}))
if not result then
Questie.db.char.TrackerLocation = nil
frm:SetPoint("CENTER",0,0)
end
end
else
result, error = pcall(frm.SetPoint, frm, unpack({QuestWatchFrame:GetPoint()}))
if not result then
Questie.db.char.TrackerLocation = nil
print(QuestieLocale:GetUIString('TRACKER_INVALID_LOCATION'))
frm:SetPoint("CENTER",0,0)
end
end
Thanks for your report! You're correct that this is a really bad bug and a result of a bad code styling.
We've already fixed this issue on a different branch which we're testing currently. We want to get the changes together with quest fixes out very soon. Keep an eye out for 4.1.2
Not code styling 76d679e#diff-f96cec2a70dc3e6b62b0e1b4cb445acd
a mistake