Bugfix: default file to play on default torrents

This commit is contained in:
DC
2016-05-23 05:42:37 -07:00
parent 4b5b84a0fc
commit 8dfdb34d31

View File

@@ -998,6 +998,7 @@ function openPlayer (infoHash, index, cb) {
// automatically choose which file in the torrent to play, if necessary
if (index === undefined) index = torrentSummary.defaultPlayFileIndex
if (index === undefined) index = pickFileToPlay(torrentSummary.files)
if (index === undefined) return cb(new errors.UnplayableError())
// update UI to show pending playback