Skip to content

Commit

Permalink
fix bug in to: filtering rules
Browse files Browse the repository at this point in the history
  • Loading branch information
Kevin Meredith committed Aug 15, 2018
1 parent a6a2465 commit 5598921
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 4 deletions.
9 changes: 7 additions & 2 deletions ews_cli/rules.py
Original file line number Diff line number Diff line change
Expand Up @@ -116,8 +116,13 @@ def process_msg(self, item):
if m.to_email != '':
if len(rule.to_list) > 0:
for to_email in m.to_or_cc_list:
if to_email in ', '.join(rule.to_list):
return rule.folder
for entry in rule.to_list:
if rule.partial == False:
if entry == to_email:
return rule.folder
else:
if entry in to_email:
return rule.folder
# Reply-To:
if m.reply_to != '':
if rule.reply_to != '':
Expand Down
4 changes: 2 additions & 2 deletions setup.py
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
from setuptools import setup

setup(name='ews-cli',
version='0.1.0.1',
version='0.1.0.2',
description='Filter email via EWS endpoint',
url='https://github.com/KebinuChiousu/ews_cli',
download_url='https://github.com/KebinuChiousu/ews_cli/archive/v0.1.0.1.tar.gz',
download_url='https://github.com/KebinuChiousu/ews_cli/archive/v0.1.0.2.tar.gz',
author='Kevin Meredith',
author_email='kevin@meredithkm.info',
license='MIT',
Expand Down

0 comments on commit 5598921

Please sign in to comment.