added http status code check to ensure the email only sends with code 200
changed preview email header