code reduce
This commit is contained in:
parent
69b305a3c9
commit
753f267fde
1 changed files with 4 additions and 8 deletions
|
@ -130,8 +130,7 @@ class Playlist():
|
||||||
else:
|
else:
|
||||||
pl['params']['item'] = {'file': url}
|
pl['params']['item'] = {'file': url}
|
||||||
|
|
||||||
result = xbmc.executeJSONRPC(json.dumps(pl))
|
self.logMsg(xbmc.executeJSONRPC(json.dumps(pl)), 2)
|
||||||
self.logMsg(result, 2)
|
|
||||||
|
|
||||||
def addtoPlaylist_xbmc(self, playlist, item):
|
def addtoPlaylist_xbmc(self, playlist, item):
|
||||||
|
|
||||||
|
@ -165,8 +164,7 @@ class Playlist():
|
||||||
else:
|
else:
|
||||||
pl['params']['item'] = {'file': url}
|
pl['params']['item'] = {'file': url}
|
||||||
|
|
||||||
result = xbmc.executeJSONRPC(json.dumps(pl))
|
self.logMsg(xbmc.executeJSONRPC(json.dumps(pl)), 2)
|
||||||
self.logMsg(result, 2)
|
|
||||||
|
|
||||||
def verifyPlaylist(self):
|
def verifyPlaylist(self):
|
||||||
|
|
||||||
|
@ -180,8 +178,7 @@ class Playlist():
|
||||||
'playlistid': 1
|
'playlistid': 1
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
result = xbmc.executeJSONRPC(json.dumps(pl))
|
self.logMsg(xbmc.executeJSONRPC(json.dumps(pl)), 2)
|
||||||
self.logMsg(result, 2)
|
|
||||||
|
|
||||||
def removefromPlaylist(self, position):
|
def removefromPlaylist(self, position):
|
||||||
|
|
||||||
|
@ -196,5 +193,4 @@ class Playlist():
|
||||||
'position': position
|
'position': position
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
result = xbmc.executeJSONRPC(json.dumps(pl))
|
self.logMsg(xbmc.executeJSONRPC(json.dumps(pl)), 2)
|
||||||
self.logMsg(result, 2)
|
|
||||||
|
|
Loading…
Reference in a new issue