refactor 'newBigAttachment' based on source from 'Add From Server' plugin