Skip to content

Commit

Permalink
fix: 修复获取自定义歌单接口报错
Browse files Browse the repository at this point in the history
  • Loading branch information
hanxi committed Dec 22, 2024
1 parent 7ded7a0 commit c09baaa
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
1 change: 1 addition & 0 deletions xiaomusic/httpserver.py
Original file line number Diff line number Diff line change
Expand Up @@ -580,6 +580,7 @@ async def playlistupdatename(
@app.get("/playlistnames")
async def getplaylistnames(Verifcation=Depends(verification)):
names = xiaomusic.get_play_list_names()
log.info(f"names {names}")
return {
"ret": "OK",
"names": names,
Expand Down
2 changes: 1 addition & 1 deletion xiaomusic/xiaomusic.py
Original file line number Diff line number Diff line change
Expand Up @@ -1176,7 +1176,7 @@ def play_list_update_name(self, oldname, newname):
# 获取所有自定义歌单
def get_play_list_names(self):
custom_play_list = self.get_custom_play_list()
return custom_play_list.keys()
return list(custom_play_list.keys())

# 获取歌单中所有歌曲
def play_list_musics(self, name):
Expand Down

0 comments on commit c09baaa

Please sign in to comment.