diff --git a/filter-rules.py b/filter-rules.py index 9e8afd7..b589150 100644 --- a/filter-rules.py +++ b/filter-rules.py @@ -92,10 +92,13 @@ def filter_message(self, message): normalized_to = [x.address.lower() for x in message.to] normalized_from = message.sender.address.lower() - # filter unactionable coresys, IAR Systems emails - if ('coresys@lists.oregonstate.edu' in normalized_from - or 'iar.ref@oregonstate.edu' in normalized_from - or 'iar.systems-team@oregonstate.edu' in normalized_to): + # filter unactionable IAR emails + automated_sources = [ + 'coresys@lists.oregonstate.edu', + 'iar.ref@oregonstate.edu', + 'Scholarship System' + ] + if bool([x for x in automated_sources if(x in normalized_from)]): unactionable = [x.lower() for x in [ 'DWPRODRAW Verification', 'Job Monitor',