diff options
author | Matthew Wild <mwild1@gmail.com> | 2016-01-22 13:20:00 +0000 |
---|---|---|
committer | Matthew Wild <mwild1@gmail.com> | 2016-01-22 13:20:00 +0000 |
commit | f9bec76a46fe06d38d82f11489a191574302bc21 (patch) | |
tree | a95e688d74d29dc16986f523ef2ef7ed4aef491f /plugins | |
parent | bd64d50dd4408de6e75856fe25c1ee41aa7b78f9 (diff) | |
download | prosody-f9bec76a46fe06d38d82f11489a191574302bc21.tar.gz prosody-f9bec76a46fe06d38d82f11489a191574302bc21.zip |
mod_admin_telnet: Fix sorting of JIDs in c2s:show() family of functions (thanks lookshe and Zash)
Diffstat (limited to 'plugins')
-rw-r--r-- | plugins/mod_admin_telnet.lua | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/plugins/mod_admin_telnet.lua b/plugins/mod_admin_telnet.lua index 73698ada..9dfbbc7a 100644 --- a/plugins/mod_admin_telnet.lua +++ b/plugins/mod_admin_telnet.lua @@ -557,11 +557,11 @@ local function show_c2s(callback) c2s:sort(function(a, b) if a.host == b.host then if a.username == b.username then - return a.resource or "" > b.resource or ""; + return (a.resource or "") > (b.resource or ""); end - return a.username or "" > b.username or ""; + return (a.username or "") > (b.username or ""); end - return a.host or "" > b.host or ""; + return (a.host or "") > (b.host or ""); end):map(function (session) callback(get_jid(session), session) end); |