From e0d255bbdc53e1e8ae2af2c358dde8d44c41ad1e Mon Sep 17 00:00:00 2001 From: LAX18 Development Date: Sat, 4 Jun 2022 20:21:45 -0400 Subject: [PATCH] Oops --- js/schedules.js | 2 +- python/api.py | 8 -------- 2 files changed, 1 insertion(+), 9 deletions(-) diff --git a/js/schedules.js b/js/schedules.js index 86aa19e..e72363b 100644 --- a/js/schedules.js +++ b/js/schedules.js @@ -141,7 +141,7 @@ function retrieveSchedule(airport, state) { var xhr = new XMLHttpRequest(); - xhr.open("POST", "http://"+window.location.hostname+":5000/url", true); + xhr.open("POST", "http://"+window.location.hostname+":5000/curl", true); xhr.setRequestHeader('Content-Type', 'application/json'); xhr.onreadystatechange = function () { if (xhr.readyState === 4) { diff --git a/python/api.py b/python/api.py index 32f5413..1fdc9c5 100644 --- a/python/api.py +++ b/python/api.py @@ -50,14 +50,6 @@ def volume(): level = os.popen('vol').read() return str(level) -@app.route('/cmd',methods = ['POST']) -def command(): - if request.method == 'POST': - json = request.get_json() - output = os.popen("cd /usr/share/dump1090-mutability/html && "+json['command']).read() - #output = os.popen(json['command']).read() - return str(output) - @app.route('/curl',methods = ['POST']) def curl(): if request.method == 'POST':