# HG changeset patch # User Matthew Wild # Date 1408208108 -3600 # Node ID 5410f5c30d63f42fa6fce602325d820bb5bc2b1f # Parent b3e692ee16b58c9832b1dd44e033d1d5ba0d03d3 mod_privacy_lists: Correctly sort the list rules by order (thanks Flow). Fixes issue #58 diff -r b3e692ee16b5 -r 5410f5c30d63 mod_privacy_lists/mod_privacy_lists.lua --- a/mod_privacy_lists/mod_privacy_lists.lua Fri Aug 15 21:17:58 2014 +0100 +++ b/mod_privacy_lists/mod_privacy_lists.lua Sat Aug 16 17:55:08 2014 +0100 @@ -175,7 +175,7 @@ list.items[#list.items + 1] = tmp; end - table.sort(list, function(a, b) return a.order < b.order; end); + table.sort(list.items, function(a, b) return a.order < b.order; end); origin.send(st.reply(stanza)); if bare_sessions[bare_jid] ~= nil then