changes to the summary email code