Added support of attachments.