fix whel delete from db and getting torrent

This commit is contained in:
YouROK
2020-12-11 15:48:02 +03:00
parent 92ac53257b
commit 27675c89f2

View File

@@ -59,18 +59,20 @@ func GetTorrent(hashHex string) *Torrent {
return tor
}
tor = GetTorrentDB(hash)
go func() {
tr, _ := NewTorrent(tor.TorrentSpec, bts)
if tr != nil {
tr.Title = tor.Title
tr.Poster = tor.Poster
tr.Size = tor.Size
tr.Timestamp = tor.Timestamp
tr.GotInfo()
}
}()
tr := GetTorrentDB(hash)
if tr != nil {
tor = tr
go func() {
tr, _ := NewTorrent(tor.TorrentSpec, bts)
if tr != nil {
tr.Title = tor.Title
tr.Poster = tor.Poster
tr.Size = tor.Size
tr.Timestamp = tor.Timestamp
tr.GotInfo()
}
}()
}
return tor
}