Comparison

plugins/mod_storage_xep0227.lua @ 12456:64722dcb0b8c 0.12

mod_storage_xep0227: Improve logging What were we looking at?
author Kim Alvefur <zash@zash.se>
date Tue, 29 Mar 2022 19:58:28 +0200
parent 12454:b2438f374b3e
child 12457:8b7895266e99
comparison
equal deleted inserted replaced
12454:b2438f374b3e 12456:64722dcb0b8c
57 if user and user.name == "user" then 57 if user and user.name == "user" then
58 return user; 58 return user;
59 end 59 end
60 end 60 end
61 end 61 end
62 module:log("warn", "Unable to find user element"); 62 module:log("warn", "Unable to find user element in %s", xml and xml:top_tag() or "nothing");
63 end 63 end
64 local function createOuterXml(user, host) 64 local function createOuterXml(user, host)
65 return st.stanza("server-data", {xmlns='urn:xmpp:pie:0'}) 65 return st.stanza("server-data", {xmlns='urn:xmpp:pie:0'})
66 :tag("host", {jid=host}) 66 :tag("host", {jid=host})
67 :tag("user", {name = user}); 67 :tag("user", {name = user});