ipaddr is not available anymore

This commit is contained in:
Romain Bignon 2011-12-15 13:37:33 +01:00
commit 793810fdf3
2 changed files with 8 additions and 1 deletions

View file

@ -47,6 +47,9 @@ class AntiSpam(object):
return False
if profile['about2'].endswith('mmmmmmmmmmmmmmmm'):
return False
return True
# ipaddr is not available anymore.
for ipaddr in (profile['last_ip'], profile['first_ip']):
if ipaddr.startswith('41.202.'):
return False
@ -77,6 +80,9 @@ class AntiSpam(object):
if not self.check_profile(contact.aum_profile):
return False
return True
# ipaddr is not available anymore.
first_ip = contact.profile['info']['IPaddr'].value.split(' ')[0]
last_ip = contact.profile['info']['IPaddr'].value.rstrip(')')
for ipaddr in (first_ip, last_ip):