summaryrefslogtreecommitdiff
path: root/src/command.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/command.cpp')
-rw-r--r--src/command.cpp15
1 files changed, 3 insertions, 12 deletions
diff --git a/src/command.cpp b/src/command.cpp
index d51836b22..7925e8bbd 100644
--- a/src/command.cpp
+++ b/src/command.cpp
@@ -1,7 +1,7 @@
/*
*
* (C) 2008-2011 Robin Burchell <w00t@inspircd.org>
- * (C) 2008-2023 Anope Team <team@anope.org>
+ * (C) 2008-2024 Anope Team <team@anope.org>
*
* Please read COPYING and README for further details.
*/
@@ -122,10 +122,6 @@ Command::Command(Module *o, const Anope::string &sname, size_t minparams, size_t
allow_unregistered = require_user = false;
}
-Command::~Command()
-{
-}
-
void Command::SetDesc(const Anope::string &d)
{
this->desc = d;
@@ -292,15 +288,10 @@ bool Command::FindCommandFromService(const Anope::string &command_service, BotIn
{
bot = NULL;
- for (botinfo_map::iterator it = BotListByNick->begin(), it_end = BotListByNick->end(); it != it_end; ++it)
+ for (const auto &[_, bi] : *BotListByNick)
{
- BotInfo *bi = it->second;
-
- for (CommandInfo::map::const_iterator cit = bi->commands.begin(), cit_end = bi->commands.end(); cit != cit_end; ++cit)
+ for (const auto &[c_name, info] : bi->commands)
{
- const Anope::string &c_name = cit->first;
- const CommandInfo &info = cit->second;
-
if (info.name != command_service)
continue;