summaryrefslogtreecommitdiff
path: root/backend
diff options
context:
space:
mode:
authorLouie S <louie@example.com>2023-04-03 20:04:52 -0700
committerLouie S <louie@example.com>2023-04-03 20:04:52 -0700
commitd8c68fe9cc59f667478bb763cf690d8f771afa59 (patch)
treedaab2a55b7b5e77fd138e1913ff7db6dd553f5e9 /backend
parente45d210517ae56abfec61ce1a8db1fc6ed7c4b4b (diff)
Fix refresh issue
Diffstat (limited to 'backend')
-rw-r--r--backend/__pycache__/config.cpython-39.pycbin413 -> 413 bytes
-rw-r--r--backend/endpoints/__pycache__/get_plist.cpython-39.pycbin1814 -> 1816 bytes
-rw-r--r--backend/endpoints/get_plist.py4
-rw-r--r--backend/server.py2
4 files changed, 3 insertions, 3 deletions
diff --git a/backend/__pycache__/config.cpython-39.pyc b/backend/__pycache__/config.cpython-39.pyc
index 03ffd8d..4c9478f 100644
--- a/backend/__pycache__/config.cpython-39.pyc
+++ b/backend/__pycache__/config.cpython-39.pyc
Binary files differ
diff --git a/backend/endpoints/__pycache__/get_plist.cpython-39.pyc b/backend/endpoints/__pycache__/get_plist.cpython-39.pyc
index 5410abf..892892d 100644
--- a/backend/endpoints/__pycache__/get_plist.cpython-39.pyc
+++ b/backend/endpoints/__pycache__/get_plist.cpython-39.pyc
Binary files differ
diff --git a/backend/endpoints/get_plist.py b/backend/endpoints/get_plist.py
index 1fda2d5..07d7b3a 100644
--- a/backend/endpoints/get_plist.py
+++ b/backend/endpoints/get_plist.py
@@ -9,8 +9,6 @@ from config import Config
class Get_Plist:
output = dict()
- output["docsets"] = []
-
def find_plist(path):
with os.scandir(path) as it:
@@ -46,6 +44,8 @@ class Get_Plist:
def main():
+ Get_Plist.output["docsets"] = []
+
if not os.path.isdir(Config.docset_base):
e = "Invalid DOCSET_BASE \"" + Config.docset_base + "\""
logging.error(e);
diff --git a/backend/server.py b/backend/server.py
index 477ad15..231a16a 100644
--- a/backend/server.py
+++ b/backend/server.py
@@ -9,11 +9,11 @@ class MyServer(http.server.BaseHTTPRequestHandler):
self.send_header("Content-type", "application/json")
self.send_header("Access-Control-Allow-Origin", "*")
self.send_header("Access-Control-Allow-Headers", "content-type")
+
self.end_headers()
output = Get_Plist.main()
self.wfile.write(output.encode())
-
if __name__ == "__main__":
webServer = http.server.HTTPServer((Config.hostName, Config.serverPort), MyServer)
print("Server started http://%s:%s" % (Config.hostName, Config.serverPort))