torrent.go | 4 +++- diff --git a/torrent.go b/torrent.go index f0dd4c07a72238e34ee8d9fb649d4f8cd6ddd572..711b58c4faa0c6e72a1bc662874aeb668bf91468 100644 --- a/torrent.go +++ b/torrent.go @@ -336,6 +336,8 @@ t.MetaData = make([]byte, bytes) t.metadataHave = make([]bool, (bytes+(1<<14)-1)/(1<<14)) } +// The current working name for the torrent. Either the name in the info dict, +// or a display name given such as by the dn value in a magnet link, or "". func (t *torrent) Name() string { if t.haveInfo() { return t.Info.Name @@ -343,7 +345,7 @@ } if t.DisplayName != "" { return t.DisplayName } - return t.InfoHash.HexString() + return "" } func (t *torrent) pieceStatusChar(index int) byte {