fix setting of content type when email attachments are present
- currently when the content type is changed all parameters are dropped. Most importantly the 'boundary' parameter is dropped and confuses some mail clients, including Gmail