Only admins should be able to load email module.

git-svn-id: https://znc.svn.sourceforge.net/svnroot/znc/trunk@2266 726aef4b-f618-498e-8847-2d620e286838
This commit is contained in:
darthgandalf
2011-01-15 17:08:57 +00:00
parent 37b70a2949
commit 81c864d025
+6
View File
@@ -48,6 +48,12 @@ public:
virtual ~CEmail() {}
virtual bool OnLoad(const CString & sArgs, CString& sMessage) {
#ifndef MOD_EMAIL_ALLOW_EVERYONE
if (!m_pUser->IsAdmin()) {
sMessage = "You must be admin to use the email module";
return false;
}
#endif
m_sMailPath = sArgs;
StartParser();