You've already forked RadioPlayer
mirror of
https://github.com/radio95-rnt/RadioPlayer.git
synced 2026-02-27 14:13:55 +01:00
fucking hell
This commit is contained in:
@@ -283,8 +283,13 @@ class PlaylistManager:
|
|||||||
while full_filepath in lines:
|
while full_filepath in lines:
|
||||||
lines.remove(full_filepath)
|
lines.remove(full_filepath)
|
||||||
|
|
||||||
with open(playlist_file, 'w') as f:
|
with open(playlist_file, 'w', encoding='utf-8', errors='strict') as f:
|
||||||
f.write('\n'.join(lines) + ('\n' if lines else ''))
|
for line in lines:
|
||||||
|
try:
|
||||||
|
f.write(line + '\n')
|
||||||
|
except UnicodeEncodeError as e:
|
||||||
|
print("⚠️ Encoding error in line:", repr(line))
|
||||||
|
raise
|
||||||
|
|
||||||
def is_file_item_in_playlist(self, file_item: FileItem, day: str, period: str, playlists: Dict) -> bool:
|
def is_file_item_in_playlist(self, file_item: FileItem, day: str, period: str, playlists: Dict) -> bool:
|
||||||
"""Check if ALL files from a FileItem are in the specified playlist."""
|
"""Check if ALL files from a FileItem are in the specified playlist."""
|
||||||
|
|||||||
Reference in New Issue
Block a user