docs: public static Attachment writeAttachment(byte[] attachment, String title) throws IOException {
          String type = getDefaultMimeTypes().detect(new ByteArrayInputStream(attachment), new Metadata()).toString();
          return writeAttachment(attachment, title, type);
      }