Random lua error after the last update
Pocokk opened this issue · 1 comments
2x Guildbook/GuildbookMixin.lua:473: attempt to compare nil with string
[string "@Guildbook/GuildbookMixin.lua"]:473: in function <Guildbook/GuildbookMixin.lua:461>
[string "=[C]"]: in function sort' [string "@Guildbook/GuildbookMixin.lua"]:461: in function
UpdateMinimapTooltip'
[string "@Guildbook/GuildbookMixin.lua"]:514: in function `UpdateTooltip'
[string "@Guildbook/GuildbookMixin.lua"]:519: in function <Guildbook/GuildbookMixin.lua:517>
Locals:
a =
classID = 2
level = 80
name = "Iringobeax-MirageRaceway"
}
b =
classID = 2
level = 80
name = "Omän-MirageRaceway"
zone = "Darnassus"
}
(*temporary) = nil
(*temporary) = "Darnassus"
(*temporary) = "attempt to compare nil with string"
Hi thanks, I think the issue is where the client hasn't got a players location, maybe due to an instance or RDF group.
I have added some checks around this now to prevent nil values going into the sort function.
if (name ~= nil) and (obj.data.class ~= nil) and (obj.data.level ~= nil) and obj.data.onlineStatus.isOnline then table.insert(t, { name = name, classID = obj.data.class, level = obj.data.level, zone = obj.data.onlineStatus.zone or "-", }) end