mirror of
https://github.com/THIS-IS-NOT-A-BACKUP/zspotify.git
synced 2025-07-01 07:13:14 +00:00
Fixed sanitizer
This commit is contained in:
parent
7546e76865
commit
f95f7af40c
@ -44,10 +44,11 @@ def wait(seconds: int = 3):
|
||||
|
||||
|
||||
def sanitize_data(value):
|
||||
global sanitize
|
||||
""" Returns given string with problematic removed """
|
||||
for i in sanitize:
|
||||
sanitized_value = value.replace(i, "")
|
||||
return sanitized_value.replace("|", "-")
|
||||
value = value.replace(i, "")
|
||||
return value.replace("|", "-")
|
||||
|
||||
|
||||
def splash():
|
||||
@ -445,7 +446,6 @@ def download_track(track_id_str: str, extra_paths=""):
|
||||
while True:
|
||||
# Trys to read exactly 128kb at a time to be more efficient now
|
||||
byte = stream.input_stream.stream().read(1024 * 128)
|
||||
print(len(byte))
|
||||
if byte == b'':
|
||||
break
|
||||
file.write(byte)
|
||||
|
Loading…
x
Reference in New Issue
Block a user