diff options
author | Adam <Adam@anope.org> | 2013-02-10 12:30:45 -0500 |
---|---|---|
committer | Adam <Adam@anope.org> | 2013-02-10 12:31:37 -0500 |
commit | fc4b884d0ea7549e5b63cd9e3c13a29aa8627c24 (patch) | |
tree | 5aaf0566aa7ecede6dd318c88d409faaa1af8108 /modules/commands/cs_list.cpp | |
parent | 9b3ecfe777d38fffb50396350ec6f37fdfcfacd7 (diff) |
Sort output in ns_list and cs_list
Diffstat (limited to 'modules/commands/cs_list.cpp')
-rw-r--r-- | modules/commands/cs_list.cpp | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/modules/commands/cs_list.cpp b/modules/commands/cs_list.cpp index d762a54ba..29c8a827b 100644 --- a/modules/commands/cs_list.cpp +++ b/modules/commands/cs_list.cpp @@ -74,7 +74,11 @@ class CommandCSList : public Command ListFormatter list; list.AddColumn("Name").AddColumn("Description"); + Anope::map<ChannelInfo *> ordered_map; for (registered_channel_map::const_iterator it = RegisteredChannelList->begin(), it_end = RegisteredChannelList->end(); it != it_end; ++it) + ordered_map[it->first] = it->second; + + for (Anope::map<ChannelInfo *>::const_iterator it = ordered_map.begin(), it_end = ordered_map.end(); it != it_end; ++it) { const ChannelInfo *ci = it->second; |