mpris: Use add(uri=uri) instead of add(lookup(uri))
This commit is contained in:
parent
f26db23de9
commit
3d847862ae
@ -279,9 +279,8 @@ class MprisObject(dbus.service.Object):
|
|||||||
return
|
return
|
||||||
# NOTE Check if URI has MIME type known to the backend, if MIME support
|
# NOTE Check if URI has MIME type known to the backend, if MIME support
|
||||||
# is added to the backend.
|
# is added to the backend.
|
||||||
tracks = self.core.library.lookup(uri).get()
|
tl_tracks = self.core.tracklist.add(uri=uri).get()
|
||||||
if tracks:
|
if tl_tracks:
|
||||||
tl_tracks = self.core.tracklist.add(tracks).get()
|
|
||||||
self.core.playback.play(tl_tracks[0])
|
self.core.playback.play(tl_tracks[0])
|
||||||
else:
|
else:
|
||||||
logger.debug('Track with URI "%s" not found in library.', uri)
|
logger.debug('Track with URI "%s" not found in library.', uri)
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user