added description overwrite and suffix support
This commit is contained in:
parent
04840b3cd5
commit
3c50bf7a5a
@ -119,13 +119,16 @@ class PlaylistEngine:
|
|||||||
logger.error('error executing')
|
logger.error('error executing')
|
||||||
return None
|
return None
|
||||||
|
|
||||||
def change_description(self, playlistparts, playlist_id, suffix=None):
|
def change_description(self, playlistparts, playlist_id, overwrite=None, suffix=None):
|
||||||
|
|
||||||
if suffix:
|
if overwrite:
|
||||||
string = ' / '.join(playlistparts) + f' - {str(suffix)}'
|
string = overwrite
|
||||||
else:
|
else:
|
||||||
string = ' / '.join(playlistparts)
|
string = ' / '.join(playlistparts)
|
||||||
|
|
||||||
|
if suffix:
|
||||||
|
string += f' - {str(suffix)}'
|
||||||
|
|
||||||
resp = self.net.change_playlist_details(playlist_id, description=string)
|
resp = self.net.change_playlist_details(playlist_id, description=string)
|
||||||
if resp:
|
if resp:
|
||||||
return resp
|
return resp
|
||||||
|
Loading…
Reference in New Issue
Block a user