diff --git a/cathedral.py b/cathedral.py index 35f6c2d..3349cb7 100644 --- a/cathedral.py +++ b/cathedral.py @@ -12,7 +12,7 @@ class cathedral(): async def handle_http(self, r): for t in self.towers: for h in t.hooks: - if compile(h.replace("$HOST", self.cfg.get("host"))).match(str(r.url)): + if compile(h.replace("$HOST", r.host.split(".")[-1])).match(str(r.url)): return web.Response(**t.run(self, r)) return web.Response(body=f"lol dongs {r.url}") async def start_http(self):