fixed addAttachment and deleteAttachment, #47