From 55989212ce51fb5ad81a4fb6e7eb404d29696d77 Mon Sep 17 00:00:00 2001 From: Kevin Meredith Date: Wed, 15 Aug 2018 15:13:33 -0400 Subject: [PATCH] fix bug in to: filtering rules --- ews_cli/rules.py | 9 +++++++-- setup.py | 4 ++-- 2 files changed, 9 insertions(+), 4 deletions(-) diff --git a/ews_cli/rules.py b/ews_cli/rules.py index e34917f..56b7296 100644 --- a/ews_cli/rules.py +++ b/ews_cli/rules.py @@ -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 != '': diff --git a/setup.py b/setup.py index 239e68f..7c99ae7 100644 --- a/setup.py +++ b/setup.py @@ -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',