only add trailers that are actually local

This commit is contained in:
im85288 2015-03-22 14:21:30 +00:00
parent 3b78b8e765
commit 4606ad5e79

View file

@ -220,6 +220,7 @@ class CreateFiles():
jsonData = downloadUtils.downloadUrl(itemTrailerUrl, suppress=True, popup=0 ) jsonData = downloadUtils.downloadUrl(itemTrailerUrl, suppress=True, popup=0 )
if(jsonData != ""): if(jsonData != ""):
trailerItem = json.loads(jsonData) trailerItem = json.loads(jsonData)
if trailerItem[0].get("LocationType") == "FileSystem":
trailerUrl = "plugin://plugin.video.mb3sync/?id=" + trailerItem[0].get("Id") + '&mode=play' trailerUrl = "plugin://plugin.video.mb3sync/?id=" + trailerItem[0].get("Id") + '&mode=play'
SubElement(root, "trailer").text = trailerUrl SubElement(root, "trailer").text = trailerUrl