Preparing for separation of the GUI from the core

This commit is contained in:
RemixDev
2020-04-14 14:23:45 +02:00
parent 1ed8e7bb20
commit 3facf299f1
2 changed files with 5 additions and 50 deletions

View File

@ -686,7 +686,9 @@ def after_download(tracks, settings, queueItem):
with open(os.path.join(extrasPath, 'playlist.m3u8'), 'w') as f:
for line in playlist:
f.write(line+"\n")
return extrasPath
if settings['executeCommand'] != "":
execute(settings['executeCommand'].replace("%folder%", extrasPath))
return track['extrasPath']
def after_download_single(track, settings, queueItem):
if 'cancel' in track:
@ -701,6 +703,8 @@ def after_download_single(track, settings, queueItem):
orig += "\r\n"
orig += track['searched']+"\r\n"
f.write(orig)
if settings['executeCommand'] != "":
execute(settings['executeCommand'].replace("%folder%", track['extrasPath']))
return track['extrasPath']
class downloadCancelled(Exception):