Skip to content

Commit

Permalink
Encoding must be set to save xml data properly on Windows (#865)
Browse files Browse the repository at this point in the history
  • Loading branch information
luzip665 committed Mar 25, 2023
1 parent aacc00b commit a2f6c8f
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion plugins/icecast/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -121,7 +121,7 @@ def _save_cache(self):
station.setAttribute('format', url['format'])
genre.appendChild(station)
genrelist.appendChild(genre)
with open(self.cache_file, 'w') as h:
with open(self.cache_file, 'w', encoding="utf-8") as h:
document.writexml(h, indent='\n', encoding='utf-8')

def get_lists(self, no_cache=False):
Expand Down

0 comments on commit a2f6c8f

Please sign in to comment.