# HG changeset patch # User Matthew Wild # Date 1556617500 -3600 # Node ID 179424d557f219d43f384c8d450201b34b877a6e # Parent b50be75c8befdc019305a1050b57480c0247db92 mod_admin_web: Fix to use format strings in logger calls (thanks Ge0rG) diff -r b50be75c8bef -r 179424d557f2 mod_admin_web/admin_web/mod_admin_web.lua --- a/mod_admin_web/admin_web/mod_admin_web.lua Mon Apr 29 00:05:20 2019 +0200 +++ b/mod_admin_web/admin_web/mod_admin_web.lua Tue Apr 30 10:45:00 2019 +0100 @@ -56,7 +56,7 @@ item:tag("compressed"):up(); end service[host]:publish(xmlns_c2s_session, host, id, item); - module:log("debug", "Added client " .. name); + module:log("debug", "Added client %s", name); end local function del_client(session, host) @@ -96,7 +96,7 @@ item:tag("compressed"):up(); end service[host]:publish(xmlns_s2s_session, host, id, item); - module:log("debug", "Added host " .. name .. " s2s" .. type); + module:log("debug", "Added host %s s2s%s", name, type); end local function del_host(session, type, host) @@ -219,7 +219,7 @@ -- Create node for s2s sessions local ok, err = service[module.host]:create(xmlns_s2s_session, true); if not ok then - module:log("warn", "Could not create node " .. xmlns_s2s_session .. ": " .. tostring(err)); + module:log("warn", "Could not create node %s: %s", xmlns_s2s_session, err); else service[module.host]:set_affiliation(xmlns_s2s_session, true, module.host, "owner") end @@ -241,7 +241,7 @@ -- Create node for c2s sessions ok, err = service[module.host]:create(xmlns_c2s_session, true); if not ok then - module:log("warn", "Could not create node " .. xmlns_c2s_session .. ": " .. tostring(err)); + module:log("warn", "Could not create node %s: %s", xmlns_c2s_session, tostring(err)); else service[module.host]:set_affiliation(xmlns_c2s_session, true, module.host, "owner") end