only return IRCUser.hostmask() when all needed pieces are available
This commit is contained in:
parent
bc63111984
commit
a42a196720
1 changed files with 3 additions and 1 deletions
|
@ -33,7 +33,9 @@ class User(IRCObject.Object):
|
|||
return self.nickname
|
||||
|
||||
def hostmask(self) -> str:
|
||||
if self.nickname and self.username and self.hostname:
|
||||
return "%s!%s@%s" % (self.nickname, self.username, self.hostname)
|
||||
return None
|
||||
|
||||
def get_id(self)-> int:
|
||||
return (self.identified_account_id_override or
|
||||
|
|
Loading…
Reference in a new issue