improvement of antispam
This commit is contained in:
parent
97fe89ab66
commit
0a61ecc6c2
2 changed files with 21 additions and 2 deletions
|
|
@ -164,7 +164,7 @@ class AuMBackend(BaseBackend, ICapMessages, ICapMessagesPost, ICapDating, ICapCh
|
|||
if not mail['id_from'] in contacts:
|
||||
with self.browser:
|
||||
contacts[mail['id_from']] = self.get_contact(mail['id_from'])
|
||||
if self.antispam and not self.antispam.check_profile(contacts[mail['id_from']].aum_profile):
|
||||
if self.antispam and not self.antispam.check_contact(contacts[mail['id_from']]):
|
||||
self.logger.info('Skipped a spam-mail-profile from %s' % mails['member']['pseudo'])
|
||||
self.report_spam(thread.id)
|
||||
break
|
||||
|
|
@ -240,7 +240,7 @@ class AuMBackend(BaseBackend, ICapMessages, ICapMessagesPost, ICapDating, ICapCh
|
|||
if basket['isBan'] or parse_dt(basket['date']) <= slut['lastmsg']:
|
||||
continue
|
||||
contact = self.get_contact(basket['id'])
|
||||
if self.antispam and not self.antispam.check_profile(contact.aum_profile):
|
||||
if self.antispam and not self.antispam.check_contact(contact):
|
||||
self.logger.info('Skipped a spam-basket from %s' % contact.name)
|
||||
self.report_spam(basket['id'])
|
||||
continue
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue