X-Git-Url: https://git.enpas.org/?a=blobdiff_plain;ds=sidebyside;f=util%2Fstanza.lua;h=afaf9ce90b47e395d442c30b47a3bf2a95171bbe;hb=2cf93bbbe48b948a7aee22f172ffc1287baedd6c;hp=307a858ade8e8c2289235b5e85fa80aeaf8305ec;hpb=b9d6bc74329d898276fe4cb7b51bae4776e4f5ec;p=prosody.git diff --git a/util/stanza.lua b/util/stanza.lua index 307a858a..afaf9ce9 100644 --- a/util/stanza.lua +++ b/util/stanza.lua @@ -242,7 +242,7 @@ function stanza_mt.get_error(stanza) end type = error_tag.attr.type; - for child in error_tag:children() do + for child in error_tag:childtags() do if child.attr.xmlns == xmlns_stanzas then if not text and child.name == "text" then text = child:get_text(); @@ -254,7 +254,7 @@ function stanza_mt.get_error(stanza) end end end - return type, condition or "undefined-condition", text or ""; + return type, condition or "undefined-condition", text; end function stanza_mt.__add(s1, s2)