diff options
| author | Adam <Adam@anope.org> | 2011-08-25 16:21:21 -0400 |
|---|---|---|
| committer | Adam <Adam@anope.org> | 2011-09-10 01:58:38 -0400 |
| commit | f025d1b495cee3aadb6b7b45652d1cab3b7b7b6d (patch) | |
| tree | 02df5a3f12104996af87d1b6c5ec9db9d45b6bde /modules/commands/os_sxline.cpp | |
| parent | 8c4417cad180f3c5448c5b7509b1bf2235e3077e (diff) | |
Made service_reference type safe
Diffstat (limited to 'modules/commands/os_sxline.cpp')
| -rw-r--r-- | modules/commands/os_sxline.cpp | 15 |
1 files changed, 8 insertions, 7 deletions
diff --git a/modules/commands/os_sxline.cpp b/modules/commands/os_sxline.cpp index c1d620914..80ad9db8c 100644 --- a/modules/commands/os_sxline.cpp +++ b/modules/commands/os_sxline.cpp @@ -320,8 +320,11 @@ class CommandOSSNLine : public CommandOSSXLineBase void OnAdd(CommandSource &source, const std::vector<Anope::string> ¶ms) { - if (!this->xlm()) + if (!this->xlm() ||! ircd->snline) + { + source.Reply(_("Your IRCd does not support SNLINE")); return; + } User *u = source.u; unsigned last_param = 2; @@ -491,8 +494,11 @@ class CommandOSSQLine : public CommandOSSXLineBase void OnAdd(CommandSource &source, const std::vector<Anope::string> ¶ms) { - if (!this->xlm()) + if (!this->xlm() ||! ircd->sqline) + { + source.Reply(_("Your IRCd does not support SQLINE")); return; + } User *u = source.u; unsigned last_param = 2; @@ -643,11 +649,6 @@ class OSSXLine : public Module commandossnline(this), commandossqline(this) { this->SetAuthor("Anope"); - - if (ircd && ircd->snline) - ModuleManager::RegisterService(&commandossnline); - if (ircd && ircd->sqline) - ModuleManager::RegisterService(&commandossqline); } }; |
