diff options
| author | 2014-06-13 15:40:03 +0200 | |
|---|---|---|
| committer | 2014-06-13 15:40:03 +0200 | |
| commit | 085a8a34cb0b1bd97bba76fff15820fb57aa50e4 (patch) | |
| tree | edbbb57fa80ac5da15b8c41e9c85976c4ff2414b /src/configreader.cpp | |
| parent | Use CommandParser::GetHandler() in ServerConfig::ApplyDisabledCommands() (diff) | |
Add CommandParser::GetCommands() and typedef CommandMap and use it instead of directly accessing cmdlist
Diffstat (limited to 'src/configreader.cpp')
| -rw-r--r-- | src/configreader.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/configreader.cpp b/src/configreader.cpp index 1ac075557..945600e6c 100644 --- a/src/configreader.cpp +++ b/src/configreader.cpp @@ -69,7 +69,8 @@ bool ServerConfig::ApplyDisabledCommands(const std::string& data) std::string thiscmd; /* Enable everything first */ - for (Commandtable::iterator x = ServerInstance->Parser->cmdlist.begin(); x != ServerInstance->Parser->cmdlist.end(); x++) + const CommandParser::CommandMap& commands = ServerInstance->Parser->GetCommands(); + for (CommandParser::CommandMap::const_iterator x = commands.begin(); x != commands.end(); ++x) x->second->Disable(false); /* Now disable all the ones which the user wants disabled */ |
