Use Info.BestName in a few more places
This commit is contained in:
parent
aa4a831c78
commit
dd1ca6f514
|
@ -72,7 +72,7 @@ func (mi *MetaInfo) SetDefaults() {
|
|||
func (mi *MetaInfo) Magnet(infoHash *Hash, info *Info) (m Magnet) {
|
||||
m.Trackers = append(m.Trackers, mi.UpvertedAnnounceList().DistinctValues()...)
|
||||
if info != nil {
|
||||
m.DisplayName = info.Name
|
||||
m.DisplayName = info.BestName()
|
||||
}
|
||||
if infoHash != nil {
|
||||
m.InfoHash = *infoHash
|
||||
|
|
|
@ -543,7 +543,7 @@ func (t *Torrent) name() string {
|
|||
t.nameMu.RLock()
|
||||
defer t.nameMu.RUnlock()
|
||||
if t.haveInfo() {
|
||||
return t.info.Name
|
||||
return t.info.BestName()
|
||||
}
|
||||
if t.displayName != "" {
|
||||
return t.displayName
|
||||
|
|
Loading…
Reference in New Issue