]> git.netwichtig.de Git - user/henk/code/inspircd.git/blobdiff - src/modules/m_helpop.cpp
Fix sqllog compile error
[user/henk/code/inspircd.git] / src / modules / m_helpop.cpp
index 8f19bd72b739bfbae57e3363b91de7d83e942d2c..b36bf2e803e17450d518592d11428d04ae0ce26d 100644 (file)
@@ -55,7 +55,7 @@ class Helpop : public ModeHandler
 class CommandHelpop : public Command
 {
  public:
-       CommandHelpop(Module* Creator) : Command(Creator, "HELPOP", 0)
+       CommandHelpop(Module* Creator) : Command(Creator, "HELP", 0)
        {
                syntax = "<any-text>";
        }
@@ -133,11 +133,10 @@ class ModuleHelpop : public Module
 
                        helpop_map.clear();
 
-                       for (int i = 0;; i++)
+                       ConfigTagList tags = ServerInstance->Config->ConfTags("helpop");
+                       for(ConfigIter i = tags.first; i != tags.second; ++i)
                        {
-                               ConfigTag* tag = ServerInstance->Config->ConfValue("helpop", i);
-                               if (!tag)
-                                       break;
+                               ConfigTag* tag = i->second;
                                irc::string key = assign(tag->getString("key"));
                                std::string value;
                                tag->readString("value", value, true); /* Linefeeds allowed */