code: func (fh FileHeaders) writeTo31(w io.Writer) error {
  	compressionFlags := make([]byte, 4)
  	binary.LittleEndian.PutUint32(compressionFlags, fh.CompressionFlags)
  
  	transformRounds := make([]byte, 8)
  	binary.LittleEndian.PutUint64(transformRounds, fh.TransformRounds)
  
  	innerRandomStreamID := make([]byte, 4)
  	binary.LittleEndian.PutUint32(innerRandomStreamID, fh.InnerRandomStreamID)
  
  	if err := writeTo31Header(w, 1, fh.Comment); err != nil {
  		return err
  	}
  	if err := writeTo31Header(w, 2, fh.CipherID); err != nil {
  		return err
  	}
  	if err := writeTo31Header(w, 3, compressionFlags); err != nil {
  		return err
  	}
  	if err := writeTo31Header(w, 4, fh.MasterSeed); err != nil {
  		return err
  	}
  	if err := writeTo31Header(w, 5, fh.TransformSeed); err != nil {
  		return err
  	}
  	if err := writeTo31Header(w, 6, transformRounds); err != nil {
  		return err
  	}
  	if err := writeTo31Header(w, 7, fh.EncryptionIV); err != nil {
  		return err
  	}
  	if err := writeTo31Header(w, 8, fh.ProtectedStreamKey); err != nil {
  		return err
  	}
  	if err := writeTo31Header(w, 9, fh.StreamStartBytes); err != nil {
  		return err
  	}
  	if err := writeTo31Header(w, 10, innerRandomStreamID); err != nil {
  		return err
  	}
  	// End of header
  	return writeTo31Header(w, 0, []byte{0x0D, 0x0A, 0x0D, 0x0A})
  }
docs: // writeTo31 writes a Kdbx v3.1 structured file header to the given io.Writer