diff options
| author | Adam <Adam@anope.org> | 2012-11-26 22:57:51 -0500 |
|---|---|---|
| committer | Adam <Adam@anope.org> | 2012-11-26 23:09:26 -0500 |
| commit | 8a6962fc363410928dc8d7c197fd3fbf3e315597 (patch) | |
| tree | 7eac6e127be5e4b691e96a1053f114870cc449aa /modules/commands | |
| parent | f23bad140b3abf3350c552c27c4e1d995337ce79 (diff) | |
Keep track on what ircds we can svsjoin, add an svspart method
Diffstat (limited to 'modules/commands')
| -rw-r--r-- | modules/commands/ns_ajoin.cpp | 5 | ||||
| -rw-r--r-- | modules/commands/ns_recover.cpp | 4 |
2 files changed, 6 insertions, 3 deletions
diff --git a/modules/commands/ns_ajoin.cpp b/modules/commands/ns_ajoin.cpp index 54e37ad36..ce92582f6 100644 --- a/modules/commands/ns_ajoin.cpp +++ b/modules/commands/ns_ajoin.cpp @@ -233,6 +233,9 @@ class NSAJoin : public Module { this->SetAuthor("Anope"); + if (!IRCD->CanSVSJoin) + throw ModuleException("Your IRCd does not support SVSJOIN"); + Implementation i[] = { I_OnNickIdentify }; ModuleManager::Attach(i, this, sizeof(i) / sizeof(Implementation)); } @@ -317,7 +320,7 @@ class NSAJoin : public Module IRCD->SendInvite(NickServ, c, u); } - IRCD->SendSVSJoin(NickServ, u->nick, entry->channel, key); + IRCD->SendSVSJoin(NickServ, u, entry->channel, key); } } }; diff --git a/modules/commands/ns_recover.cpp b/modules/commands/ns_recover.cpp index 287224a1b..419857eee 100644 --- a/modules/commands/ns_recover.cpp +++ b/modules/commands/ns_recover.cpp @@ -243,8 +243,8 @@ class NSRecover : public Module /* User might already be on the channel */ if (u->FindChannel(c)) this->OnJoinChannel(u, c); - else - IRCD->SendSVSJoin(NickServ, u->GetUID(), cname, ""); + else if (IRCD->CanSVSJoin) + IRCD->SendSVSJoin(NickServ, u, cname, ""); } } } |
