Made downloadObject optional in streamTrack

This commit is contained in:
RemixDev 2021-10-07 14:57:09 +02:00
parent 54374c87e2
commit 7e6202b7f0
No known key found for this signature in database
GPG Key ID: B33962B465BDB51C
1 changed files with 2 additions and 2 deletions

View File

@ -41,7 +41,7 @@ def reverseStreamURL(url):
return reverseStreamPath(urlPart)
def streamTrack(outputStream, track, start=0, downloadObject=None, listener=None):
if downloadObject.isCanceled: raise DownloadCanceled
if downloadObject and downloadObject.isCanceled: raise DownloadCanceled
headers= {'User-Agent': USER_AGENT_HEADER}
chunkLength = start
isCryptedStream = "/mobile/" in track.downloadURL or "/media/" in track.downloadURL