Fixed the email sending function.
jpeg -> jpg (gmail doesn't seem to accept jpeg)