summaryrefslogtreecommitdiff
path: root/backend/decky_loader/loader.py
diff options
context:
space:
mode:
authorK900 <me@0upti.me>2024-06-27 11:46:47 +0300
committerAAGaming <aagaming@riseup.net>2024-06-29 16:53:57 -0400
commit5697d98862efa81a8ad3651e9ef68d754a58ea90 (patch)
treed131979bb50d60dbeecf4699e5c0582d5bca400e /backend/decky_loader/loader.py
parent6cd4fb5553e4e0cb89834743286ec91fa8a02731 (diff)
downloaddecky-loader-5697d98862efa81a8ad3651e9ef68d754a58ea90.tar.gz
decky-loader-5697d98862efa81a8ad3651e9ef68d754a58ea90.zip
treewide: fix package structure
The static files need to be inside the module to be installed correctly as part of the module.
Diffstat (limited to 'backend/decky_loader/loader.py')
-rw-r--r--backend/decky_loader/loader.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/backend/decky_loader/loader.py b/backend/decky_loader/loader.py
index 4fc03237..e8a073a9 100644
--- a/backend/decky_loader/loader.py
+++ b/backend/decky_loader/loader.py
@@ -106,12 +106,12 @@ class Loader:
self.watcher.disabled = False
async def handle_frontend_assets(self, request: web.Request):
- file = Path(__file__).parents[1].joinpath("static").joinpath(request.match_info["path"])
+ file = Path(__file__).parent.joinpath("static").joinpath(request.match_info["path"])
return web.FileResponse(file, headers={"Cache-Control": "no-cache"})
async def handle_frontend_locales(self, request: web.Request):
req_lang = request.match_info["path"]
- file = Path(__file__).parents[1].joinpath("locales").joinpath(req_lang)
+ file = Path(__file__).parent.joinpath("locales").joinpath(req_lang)
if exists(file):
return web.FileResponse(file, headers={"Cache-Control": "no-cache", "Content-Type": "application/json"})
else: