From 7eb3ff0048e7647a2d6690022da29043942a410e Mon Sep 17 00:00:00 2001 From: Brian Read Date: Mon, 15 Jul 2024 10:26:52 +0100 Subject: [PATCH] Ignore the mailstats email --- root/usr/bin/mailstats.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/root/usr/bin/mailstats.py b/root/usr/bin/mailstats.py index f428dc4..1933cd7 100644 --- a/root/usr/bin/mailstats.py +++ b/root/usr/bin/mailstats.py @@ -1120,6 +1120,9 @@ if __name__ == "__main__": hour = dt.hour # parse the data parsed_data = parse_data(data) + #Take out the mailstats email + if 'mailstats' in parsed_data['from-email'] and DomainName in parsed_data['from-email']: + continue # Save the data here if necessary if saveData: save_summaries_to_db(anaysis_date_obj.strftime('%Y-%m-%d'),hour,parsed_data)