]> git.netwichtig.de Git - user/henk/code/inspircd.git/blobdiff - src/modules/m_operlog.cpp
Add m_sqlutils - Currently provides ID->chan/user lookups
[user/henk/code/inspircd.git] / src / modules / m_operlog.cpp
index 564ff1018ae6fbc6c8e875a0a13a937d10ec1957..8188c49b18289813b7f640215fe3e4a6e22fb51d 100644 (file)
@@ -49,13 +49,13 @@ class ModuleOperLog : public Module
                List[I_OnPreCommand] = List[I_On005Numeric] = 1;
        }
 
-       virtual int OnPreCommand(const std::string &command, char **parameters, int pcnt, userrec *user, bool validated)
+       virtual int OnPreCommand(const std::string &command, const char** parameters, int pcnt, userrec *user, bool validated)
        {
                /* If the command doesnt appear to be valid, we dont want to mess with it. */
                if (!validated)
                        return 0;
  
-               if (*user->oper)
+               if ((*user->oper) && (IS_LOCAL(user)) && (user->HasPermission(command)))
                {
                        std::string plist = "";
                        for (int j = 0; j < pcnt; j++)