提交 20c861b7 编写于 作者: H hjdhnx

增加本地

上级 2160f744
......@@ -92,12 +92,12 @@ def clear():
rule = getParmas('rule')
if not rule:
return jsonify(error.failed('规则字段必填'))
cache_path = f'cache/{rule}.js'
cache_path = os.path.abspath(f'cache/{rule}.js')
if not os.path.exists(cache_path):
return jsonify(error.failed('服务端没有此规则的缓存文件!'))
return jsonify(error.failed('服务端没有此规则的缓存文件!'+cache_path))
os.remove(cache_path)
return jsonify(error.success('成功删除文件:'+cache_path))
if __name__ == '__main__':
# app.run(host="0.0.0.0", port=5705)
app.run(debug=True, host='0.0.0.0', port=5705)
\ No newline at end of file
app.run(host="0.0.0.0", port=5705)
# app.run(debug=True, host='0.0.0.0', port=5705)
\ No newline at end of file
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册