Fix #1324 - Add error message for empty attachments