summaryrefslogtreecommitdiff
path: root/modules/core/ns_status.cpp
diff options
context:
space:
mode:
authorAdam <Adam@anope.org>2010-08-17 19:27:37 -0400
committerAdam <Adam@anope.org>2010-08-17 19:27:37 -0400
commite65d8b2f3dfdb40858259b3bb48ef6998c31e62f (patch)
treefd845bdef5664d025ab19c262ae2c5e9d23d7bb2 /modules/core/ns_status.cpp
parent2575008baa5c9d0ca789680da1a3b81dc74786f7 (diff)
Rewrote the config reader to better handle invalid configs.
This prevents Anope from exploding when /os reload has errors.
Diffstat (limited to 'modules/core/ns_status.cpp')
-rw-r--r--modules/core/ns_status.cpp14
1 files changed, 7 insertions, 7 deletions
diff --git a/modules/core/ns_status.cpp b/modules/core/ns_status.cpp
index 7a92fe819..2ece5c328 100644
--- a/modules/core/ns_status.cpp
+++ b/modules/core/ns_status.cpp
@@ -32,31 +32,31 @@ class CommandNSStatus : public Command
while (sep.GetToken(nickbuf))
{
if (!(u2 = finduser(nickbuf))) /* Nick is not online */
- notice_lang(Config.s_NickServ, u, NICK_STATUS_REPLY, nickbuf.c_str(), 0, "");
+ notice_lang(Config->s_NickServ, u, NICK_STATUS_REPLY, nickbuf.c_str(), 0, "");
else if (u2->IsIdentified() && na && na->nc == u2->Account()) /* Nick is identified */
- notice_lang(Config.s_NickServ, u, NICK_STATUS_REPLY, nickbuf.c_str(), 3, u2->Account()->display.c_str());
+ notice_lang(Config->s_NickServ, u, NICK_STATUS_REPLY, nickbuf.c_str(), 3, u2->Account()->display.c_str());
else if (u2->IsRecognized()) /* Nick is recognised, but NOT identified */
- notice_lang(Config.s_NickServ, u, NICK_STATUS_REPLY, nickbuf.c_str(), 2, u2->Account() ? u2->Account()->display.c_str() : "");
+ notice_lang(Config->s_NickServ, u, NICK_STATUS_REPLY, nickbuf.c_str(), 2, u2->Account() ? u2->Account()->display.c_str() : "");
else if (!na) /* Nick is online, but NOT a registered */
- notice_lang(Config.s_NickServ, u, NICK_STATUS_REPLY, nickbuf.c_str(), 0, "");
+ notice_lang(Config->s_NickServ, u, NICK_STATUS_REPLY, nickbuf.c_str(), 0, "");
else
/* Nick is not identified for the nick, but they could be logged into an account,
* so we tell the user about it
*/
- notice_lang(Config.s_NickServ, u, NICK_STATUS_REPLY, nickbuf.c_str(), 1, u2->Account() ? u2->Account()->display.c_str() : "");
+ notice_lang(Config->s_NickServ, u, NICK_STATUS_REPLY, nickbuf.c_str(), 1, u2->Account() ? u2->Account()->display.c_str() : "");
}
return MOD_CONT;
}
bool OnHelp(User *u, const Anope::string &subcommand)
{
- notice_help(Config.s_NickServ, u, NICK_HELP_STATUS);
+ notice_help(Config->s_NickServ, u, NICK_HELP_STATUS);
return true;
}
void OnServHelp(User *u)
{
- notice_lang(Config.s_NickServ, u, NICK_HELP_CMD_STATUS);
+ notice_lang(Config->s_NickServ, u, NICK_HELP_CMD_STATUS);
}
};