fixing sending emails for past classes