Added check for SENDGRID_USERNAME environment variable