usermanager: Logged a clear warning when the 'admins' option is not a table.
authorWaqas Hussain <waqas20@gmail.com>
Wed, 21 Oct 2009 06:40:29 +0000 (11:40 +0500)
committerWaqas Hussain <waqas20@gmail.com>
Wed, 21 Oct 2009 06:40:29 +0000 (11:40 +0500)
core/usermanager.lua

index 04154cdb2ef5e4576f7cf33730768af2d30353ab..acc482e30f2198cdd7b3220c2ad09d1f22524296 100644 (file)
@@ -77,7 +77,7 @@ function is_admin(jid, host)
                for _,admin in ipairs(admins) do
                        if admin == jid then return true; end
                end
-       else log("debug", "Option core.admins is not a table"); end
+       elseif admins then log("warn", "Option 'admins' for host '%s' is not a table", host); end
        return nil;
 end