Software /
code /
prosody
Changeset
5593:98a485212592
mod_admin_telnet: Use stanza:get_child_text()
author | Kim Alvefur <zash@zash.se> |
---|---|
date | Fri, 17 May 2013 18:28:05 +0200 |
parents | 5592:5705e21ba24b |
children | 5595:b9c836dc8f2a |
files | plugins/mod_admin_telnet.lua |
diffstat | 1 files changed, 1 insertions(+), 6 deletions(-) [+] |
line wrap: on
line diff
--- a/plugins/mod_admin_telnet.lua Fri May 17 14:56:36 2013 +0100 +++ b/plugins/mod_admin_telnet.lua Fri May 17 18:28:05 2013 +0200 @@ -538,12 +538,7 @@ count = count + 1; local status, priority = "unavailable", tostring(session.priority or "-"); if session.presence then - status = session.presence:child_with_name("show"); - if status then - status = status:get_text() or "[invalid!]"; - else - status = "available"; - end + status = session.presence:get_child_text("show") or "available"; end print(session_flags(session, { " "..jid.." - "..status.."("..priority..")" })); end