diff --git a/src/renderer/controllers/playback-controller.js b/src/renderer/controllers/playback-controller.js index 6e6c1587..413ccd2d 100644 --- a/src/renderer/controllers/playback-controller.js +++ b/src/renderer/controllers/playback-controller.js @@ -269,6 +269,7 @@ module.exports = class PlaybackController { // update state state.playing.infoHash = infoHash state.playing.fileIndex = index + state.playing.fileName = fileSummary.name state.playing.type = TorrentPlayer.isVideo(fileSummary) ? 'video' : TorrentPlayer.isAudio(fileSummary) ? 'audio' : 'other' diff --git a/src/renderer/lib/playlist.js b/src/renderer/lib/playlist.js index 321f13e2..eb369de1 100644 --- a/src/renderer/lib/playlist.js +++ b/src/renderer/lib/playlist.js @@ -38,7 +38,7 @@ function getPreviousIndex (state) { function getCurrentLocalURL (state) { return state.server - ? state.server.localURL + '/' + state.playing.fileIndex + ? state.server.localURL + '/' + state.playing.fileIndex + '/' + encodeURIComponent(state.playing.fileName) : '' }