From 69f9998d1641846399e3d2818da4fd07ae05739a Mon Sep 17 00:00:00 2001 From: Kim Alvefur Date: Mon, 11 Jan 2016 13:44:48 +0100 Subject: MUC: Fix global access when setting 'whois', probably resulted in wrong status code return (thanks EmilyRose) --- plugins/muc/whois.lib.lua | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/plugins/muc/whois.lib.lua b/plugins/muc/whois.lib.lua index a8e1f8d4..2f492c45 100644 --- a/plugins/muc/whois.lib.lua +++ b/plugins/muc/whois.lib.lua @@ -43,7 +43,7 @@ end); module:hook("muc-config-submitted/muc#roomconfig_whois", function(event) if set_whois(event.room, event.value) then - local code = (new == 'moderators') and "173" or "172"; + local code = (event.value == 'moderators') and "173" or "172"; event.status_codes[code] = true; end end); -- cgit v1.2.3