forked from External/ergo
fix various bugs
This commit is contained in:
parent
edd161ddfd
commit
6d65335071
5 changed files with 40 additions and 28 deletions
|
|
@ -943,6 +943,10 @@ func (am *AccountManager) checkPassphrase(accountName, passphrase string) (accou
|
|||
}
|
||||
|
||||
func (am *AccountManager) AuthenticateByPassphrase(client *Client, accountName string, passphrase string) (err error) {
|
||||
// XXX check this now, so we don't allow a redundant login for an always-on client
|
||||
// even for a brief period. the other potential source of nick-account conflicts
|
||||
// is from force-nick-equals-account, but those will be caught later by
|
||||
// fixupNickEqualsAccount and if there is a conflict, they will be logged out.
|
||||
if client.registered {
|
||||
if clientAlready := am.server.clients.Get(accountName); clientAlready != nil && clientAlready.AlwaysOn() {
|
||||
return errNickAccountMismatch
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue