mirror of
https://github.com/anope/anope.git
synced 2026-07-10 19:03:13 +02:00
Clean up some of inspircds autoid code and make it not resend account name on nick change
git-svn-id: http://anope.svn.sourceforge.net/svnroot/anope/trunk@2435 5417fbe8-f217-4b02-8779-1006273d7864
This commit is contained in:
+18
-12
@@ -707,19 +707,7 @@ class InspIRCdProto : public IRCDProto
|
||||
|
||||
void SendAccountLogin(User *u, NickCore *account)
|
||||
{
|
||||
char *c;
|
||||
|
||||
send_cmd(TS6SID, "METADATA %s accountname :%s", u->GetUID().c_str(), account->display);
|
||||
|
||||
if (account->GetExt("authenticationtoken", c))
|
||||
{
|
||||
delete [] c;
|
||||
account->Shrink("authenticationtoken");
|
||||
}
|
||||
|
||||
account->Extend("authenticationtoken", sstrdup(account->display));
|
||||
|
||||
common_svsmode(u, "+r", "");
|
||||
}
|
||||
|
||||
void SendAccountLogout(User *u, NickCore *account)
|
||||
@@ -735,6 +723,24 @@ class InspIRCdProto : public IRCDProto
|
||||
return 1;
|
||||
}
|
||||
|
||||
void SetAutoIdentificationToken(User *u)
|
||||
{
|
||||
char *c;
|
||||
|
||||
if (!u->nc)
|
||||
return;
|
||||
|
||||
if (u->nc->GetExt("authenticationtoken", c))
|
||||
{
|
||||
delete [] c;
|
||||
u->nc->Shrink("authenticationtoken");
|
||||
}
|
||||
|
||||
u->nc->Extend("authenticationtoken", sstrdup(u->nc->display));
|
||||
|
||||
common_svsmode(u, "+r", NULL);
|
||||
}
|
||||
|
||||
} ircd_proto;
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user