mirror of
https://github.com/hanxi/xiaomusic.git
synced 2025-12-14 16:08:14 +08:00
fmt
This commit is contained in:
@@ -85,7 +85,7 @@ class Config:
|
||||
mute_xiaoai: bool = True
|
||||
cookie: str = ""
|
||||
use_command: bool = False
|
||||
verbose: bool = (os.getenv("XIAOMUSIC_VERBOSE", "").lower() == "true")
|
||||
verbose: bool = os.getenv("XIAOMUSIC_VERBOSE", "").lower() == "true"
|
||||
music_path: str = os.getenv("XIAOMUSIC_MUSIC_PATH", "music")
|
||||
hostname: str = os.getenv("XIAOMUSIC_HOSTNAME", "192.168.2.5")
|
||||
port: int = int(os.getenv("XIAOMUSIC_PORT", "8090"))
|
||||
|
||||
@@ -108,12 +108,14 @@ async def musiclist():
|
||||
async def curplaylist():
|
||||
return xiaomusic.get_cur_play_list()
|
||||
|
||||
|
||||
@app.route("/delmusic", methods=["POST"])
|
||||
def delmusic():
|
||||
data = request.get_json()
|
||||
log.info(data)
|
||||
xiaomusic.del_music(data["name"])
|
||||
return 'success'
|
||||
return "success"
|
||||
|
||||
|
||||
def static_path_handler(filename):
|
||||
log.debug(filename)
|
||||
|
||||
Reference in New Issue
Block a user