Fixed track download without lyrics

This commit is contained in:
RemixDev
2020-08-16 13:25:25 +02:00
parent c067ff598e
commit af06d963da
2 changed files with 3 additions and 3 deletions

View File

@ -366,7 +366,7 @@ class DownloadJob:
writepath = os.path.join(filepath, filename + extensions[track.selectedFormat])
# Save lyrics in lrc file
if self.settings['syncedLyrics'] and 'sync' in track.lyrics:
if self.settings['syncedLyrics'] and track.lyrics['sync']:
if not os.path.isfile(os.path.join(filepath, filename + '.lrc')) or settings['overwriteFile'] in ['y', 't']:
with open(os.path.join(filepath, filename + '.lrc'), 'wb') as f:
f.write(track.lyrics['sync'].encode('utf-8'))