Move directpaths out of loop

This commit is contained in:
tomkat83 2016-05-16 19:27:43 +02:00
parent d8e9ca9ffe
commit 560835fd82

View file

@ -1516,6 +1516,7 @@ def getOnDeck(viewid, mediatype, tagname, limit):
xbmcplugin.setContent(int(sys.argv[1]), 'episodes')
appendShowTitle = utils.settings('OnDeckTvAppendShow') == 'true'
appendSxxExx = utils.settings('OnDeckTvAppendSeason') == 'true'
directpaths = utils.settings('useDirectPaths') == 'true'
if utils.settings('OnDeckTVextended') == 'false':
# Chances are that this view is used on Kodi startup
# Wait till we've connected to a PMS. At most 30s
@ -1539,7 +1540,7 @@ def getOnDeck(viewid, mediatype, tagname, limit):
appendSxxExx=appendSxxExx)
API.AddStreamInfo(listitem)
pbutils.PlaybackUtils(item).setArtwork(listitem)
if utils.settings('useDirectPaths') == 'true':
if directpaths:
url = API.getFilePath()
else:
params = {