comparison mod_audit/mod_audit.lua @ 5710:15c1801e8901

mod_audit: Fix showing session details in module command The namespaced session element was not accounted for.
author Kim Alvefur <zash@zash.se>
date Mon, 13 Nov 2023 12:37:21 +0100
parents 0c9606770db1
children c782f220b3ee
comparison
equal deleted inserted replaced
5709:0c9606770db1 5710:15c1801e8901
269 print(row({ 269 print(row({
270 when = when; 270 when = when;
271 source = entry.attr.source; 271 source = entry.attr.source;
272 event_type = entry.attr.type:gsub("%-", " "); 272 event_type = entry.attr.type:gsub("%-", " ");
273 username = user; 273 username = user;
274 ip = entry:get_child_text("remote-ip"); 274 ip = entry:find("{xmpp:prosody.im/audit}session/remote-ip#");
275 location = entry:find("location@country"); 275 country = entry:find("{xmpp:prosody.im/audit}session/location@country");
276 note = entry:get_child_text("note"); 276 note = entry:get_child_text("note");
277 })); 277 }));
278 end 278 end
279 end 279 end
280 print(string.rep("-", width)); 280 print(string.rep("-", width));