func (torrent *Torrent) Bytes() []byte {
	b, err := bencode.Marshal(torrent.raw)
	if err != nil {
		panic(err)
	}
	return b
}
Bytes torrent file bytes.
package metadata
import (
	"encoding/hex"
	"errors"
	"github.com/IncSW/go-bencode"
)
var ErrInvalidMetadata = errors.New("invalid metadata")
type Torrent struct {
	raw      interface{}
	Announce string
	Info     TorrentInfo
}