fill empty title if torrent loaded

This commit is contained in:
YouROK
2021-04-27 11:28:43 +03:00
parent bda55fe162
commit 22ad3547ed

View File

@@ -52,6 +52,9 @@ func AddTorrent(spec *torrent.TorrentSpec, title, poster string, data string) (*
if title == "" && torDB != nil { if title == "" && torDB != nil {
torr.Title = torDB.Title torr.Title = torDB.Title
} }
if torr.Title == "" && torr.Torrent != nil {
torr.Title = torr.Name()
}
} }
if torr.Poster == "" { if torr.Poster == "" {
torr.Poster = poster torr.Poster = poster