chuni: fix endpoint

This commit is contained in:
Hay1tsme 2023-10-20 01:44:21 -04:00
parent 5278d1e6c1
commit b4a3a3ab9e

View File

@ -154,10 +154,10 @@ class ChuniServlet(BaseServlet):
return (f"http://{self.core_cfg.title.hostname}/{game_ver}/", "") return (f"http://{self.core_cfg.title.hostname}/{game_ver}/", "")
def render_POST(self, request: Request, game_code: int, matchers: Dict) -> bytes: def render_POST(self, request: Request, game_code: int, matchers: Dict) -> bytes:
url_path = matchers['endpoint'] endpoint = matchers['endpoint']
version = int(matchers['version']) version = int(matchers['version'])
if url_path.lower() == "ping": if endpoint.lower() == "ping":
return zlib.compress(b'{"returnCode": "1"}') return zlib.compress(b'{"returnCode": "1"}')
req_raw = request.content.getvalue() req_raw = request.content.getvalue()