mirror of
https://github.com/Mikaela/Limnoria.git
synced 2024-12-23 11:12:47 +01:00
Change the minimal number of non-wildcard characters in hostmask from 8 to 3. Closes GH-276.
Signed-off-by: James McCoy <jamessan@users.sourceforge.net>
This commit is contained in:
parent
b5eac0994a
commit
8062d9592c
@ -281,9 +281,9 @@ class IrcUser(object):
|
|||||||
def addHostmask(self, hostmask):
|
def addHostmask(self, hostmask):
|
||||||
"""Adds a hostmask to the user's hostmasks."""
|
"""Adds a hostmask to the user's hostmasks."""
|
||||||
assert ircutils.isUserHostmask(hostmask), 'got %s' % hostmask
|
assert ircutils.isUserHostmask(hostmask), 'got %s' % hostmask
|
||||||
if len(unWildcardHostmask(hostmask)) < 8:
|
if len(unWildcardHostmask(hostmask)) < 3:
|
||||||
raise ValueError, \
|
raise ValueError, \
|
||||||
'Hostmask must contain at least 8 non-wildcard characters.'
|
'Hostmask must contain at least 3 non-wildcard characters.'
|
||||||
self.hostmasks.add(hostmask)
|
self.hostmasks.add(hostmask)
|
||||||
|
|
||||||
def removeHostmask(self, hostmask):
|
def removeHostmask(self, hostmask):
|
||||||
|
Loading…
Reference in New Issue
Block a user