X-Git-Url: https://git.enpas.org/?a=blobdiff_plain;f=core%2Fxmlhandlers.lua;h=7f47cf70ad85675acb50ff24a951249a066933f0;hb=29b6d61b521109340f9a0769ef03a70f3be49404;hp=573a9604ed7ca5c045d50ef4495d186d95ac66fb;hpb=14b07e19c6db6eefe35fac05b1772e7ee9a74436;p=prosody.git diff --git a/core/xmlhandlers.lua b/core/xmlhandlers.lua index 573a9604..7f47cf70 100644 --- a/core/xmlhandlers.lua +++ b/core/xmlhandlers.lua @@ -1,4 +1,4 @@ --- Prosody IM v0.4 +-- Prosody IM -- Copyright (C) 2008-2009 Matthew Wild -- Copyright (C) 2008-2009 Waqas Hussain -- @@ -60,13 +60,14 @@ function init_xmlhandlers(session, stream_callbacks) end -- FIXME !!!!! - for i, k in ipairs(attr) do + for i=1,#attr do + local k = attr[i]; + attr[i] = nil; local ns, nm = k:match("^([^|]+)|?([^|]-)$") if ns and nm then ns = ns_prefixes[ns]; if ns then attr[ns..":"..nm] = attr[k]; - attr[i] = ns..":"..nm; attr[k] = nil; end end