Fix GMCPHandler.get_room_flags nil error when plugin had not yet received room data

main
AreiaAard 4 years ago
parent c39ad7692a
commit 7775e0889f

@ -11,7 +11,7 @@
save_state="y" save_state="y"
date_written="2021-04-11 21:00:00" date_written="2021-04-11 21:00:00"
requires="5.06" requires="5.06"
version="1.15" version="1.16"
> >
<description trim="y"> <description trim="y">
<![CDATA[ <![CDATA[
@ -668,7 +668,8 @@ end
function GMCPHandler.get_room_flags() function GMCPHandler.get_room_flags()
local flags = {} local flags = {}
for flag in GMCPHandler.prevRoom.details:gmatch("[^,]+") do local details = GMCPHandler.prevRoom.details or ""
for flag in details:gmatch("[^,]+") do
flags[flag] = true flags[flag] = true
end end
return flags return flags

Loading…
Cancel
Save