fixed to include the 'use' of 'emailreports' module in the main loop