Bug resolved when there are no emails for specified dates.