1
0
mirror of https://github.com/anope/anope.git synced 2026-06-26 17:16:39 +02:00

Removed some problematic IsRecognized checks in ms_cancel and ms_check, and fixed a variable name in logger.cpp to make clang happy

This commit is contained in:
Adam
2010-08-27 21:30:16 -04:00
parent c2ddecc2b1
commit 56045afda2
3 changed files with 4 additions and 11 deletions
+1 -3
View File
@@ -28,9 +28,7 @@ class CommandMSCancel : public Command
Anope::string name = params[0];
MemoInfo *mi;
if (!u->IsRecognized())
notice_lang(Config->s_MemoServ, u, NICK_IDENTIFY_REQUIRED, Config->s_NickServ.c_str());
else if (!(mi = getmemoinfo(name, ischan, isforbid)))
if (!(mi = getmemoinfo(name, ischan, isforbid)))
{
if (isforbid)
notice_lang(Config->s_MemoServ, u, ischan ? CHAN_X_FORBIDDEN : NICK_X_FORBIDDEN, name.c_str());
+1 -6
View File
@@ -29,12 +29,7 @@ class CommandMSCheck : public Command
struct tm *tm;
char timebuf[64];
if (!u->IsRecognized())
{
notice_lang(Config->s_MemoServ, u, NICK_IDENTIFY_REQUIRED, Config->s_NickServ.c_str());
return MOD_CONT;
}
else if (!(na = findnick(recipient)))
if (!(na = findnick(recipient)))
{
notice_lang(Config->s_MemoServ, u, NICK_X_NOT_REGISTERED, recipient.c_str());
return MOD_CONT;
+2 -2
View File
@@ -83,9 +83,9 @@ static Anope::string GetLogDate(time_t t = time(NULL))
return timestamp;
}
static inline Anope::string CreateLogName(const Anope::string &file, time_t time = time(NULL))
static inline Anope::string CreateLogName(const Anope::string &file, time_t t = time(NULL))
{
return "logs/" + file + "." + GetLogDate(time);
return "logs/" + file + "." + GetLogDate(t);
}
LogFile::LogFile(const Anope::string &name) : filename(name), stream(name.c_str(), std::ios_base::out)