mirror of
https://github.com/Ernous/TorrServerJellyfin.git
synced 2025-12-19 13:36:09 +05:00
load torrent before send
This commit is contained in:
@@ -51,9 +51,13 @@ func playList(c *gin.Context) {
|
||||
c.AbortWithStatus(http.StatusNotFound)
|
||||
return
|
||||
}
|
||||
if !tor.WaitInfo() {
|
||||
c.AbortWithError(http.StatusInternalServerError, errors.New("error get torrent info"))
|
||||
return
|
||||
|
||||
if tor.Stat == state.TorrentInDB {
|
||||
tor = torr.LoadTorrent(tor)
|
||||
if tor == nil {
|
||||
c.AbortWithError(http.StatusInternalServerError, errors.New("error get torrent info"))
|
||||
return
|
||||
}
|
||||
}
|
||||
|
||||
host := "http://" + c.Request.Host
|
||||
|
||||
Reference in New Issue
Block a user