Trying to get file uploads to work properly for attachments