Skip to content

Commit

Permalink
Update lx_script.py
Browse files Browse the repository at this point in the history
Fix display error in generated `lx-music-source-example.js` file by set encoding.
  • Loading branch information
Albert Lin authored Jan 7, 2024
1 parent c286424 commit c37fc78
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion common/lx_script.py
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ async def get_response(retry = 0):
async def get_script():
req = await get_response()
if (req.status == 200):
with open('./lx-music-source-example.js', 'w') as f:
with open('./lx-music-source-example.js', 'w', encoding='utf-8') as f:
f.write(req.text)
f.close()
logger.info('更新源脚本成功')
Expand Down

0 comments on commit c37fc78

Please sign in to comment.