summaryrefslogtreecommitdiff
path: root/modules/commands/ns_register.cpp
diff options
context:
space:
mode:
authorAdam <Adam@anope.org>2014-01-21 17:20:15 -0500
committerAdam <Adam@anope.org>2014-01-21 17:20:15 -0500
commit4d9273efa42a16380de8ac81c615eaac89052f68 (patch)
tree8c33a14022cdd5fe303fd3bd5160a5b490752c78 /modules/commands/ns_register.cpp
parent67c13b41eeda261b9b94a5cbc9eb55413b0d92cd (diff)
Unbreak account stuff from commit ccae59430ab50393f43ccc38a6a6c0c24191b601.
Diffstat (limited to 'modules/commands/ns_register.cpp')
-rw-r--r--modules/commands/ns_register.cpp11
1 files changed, 7 insertions, 4 deletions
diff --git a/modules/commands/ns_register.cpp b/modules/commands/ns_register.cpp
index 8020dd3f0..434e7d690 100644
--- a/modules/commands/ns_register.cpp
+++ b/modules/commands/ns_register.cpp
@@ -54,10 +54,13 @@ class CommandNSConfirm : public Command
if (source.GetUser())
{
- IRCD->SendLogin(source.GetUser());
- const NickAlias *na = NickAlias::Find(source.GetNick());
- if (!Config->GetModule("nickserv")->Get<bool>("nonicknameownership") && na != NULL && na->nc == source.GetAccount() && !na->nc->HasExt("UNCONFIRMED"))
- source.GetUser()->SetMode(source.service, "REGISTERED");
+ NickAlias *na = NickAlias::Find(source.GetNick());
+ if (na)
+ {
+ IRCD->SendLogin(source.GetUser(), na);
+ if (!Config->GetModule("nickserv")->Get<bool>("nonicknameownership") && na->nc == source.GetAccount() && !na->nc->HasExt("UNCONFIRMED"))
+ source.GetUser()->SetMode(source.service, "REGISTERED");
+ }
}
}
else