From 570081c04be3dac448749b41f30303e73ab1b0d6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Dagfinn=20Ilmari=20Manns=C3=A5ker?= Date: Sun, 20 Oct 2024 21:16:00 +0100 Subject: [PATCH] Fix setting media endpoint The attribute was renamed from `endpoint` to `media_endpoint` in #290, but the control room `mediaurl` handler missed the memo. --- heisenbridge/control_room.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/heisenbridge/control_room.py b/heisenbridge/control_room.py index 1dee131..4f57060 100644 --- a/heisenbridge/control_room.py +++ b/heisenbridge/control_room.py @@ -570,19 +570,19 @@ async def cmd_media_url(self, args): if args.remove: self.serv.config["media_url"] = None await self.serv.save() - self.serv.endpoint = await self.serv.detect_public_endpoint() + self.serv.media_endpoint = await self.serv.detect_public_endpoint() elif args.url: parsed = urlparse(args.url) if parsed.scheme in ["http", "https"] and not parsed.params and not parsed.query and not parsed.fragment: self.serv.config["media_url"] = args.url await self.serv.save() - self.serv.endpoint = args.url + self.serv.media_endpoint = args.url else: self.send_notice(f"Invalid media URL format: {args.url}") return self.send_notice(f"Media URL override is set to {self.serv.config['media_url']}") - self.send_notice(f"Current active media URL: {self.serv.endpoint}") + self.send_notice(f"Current active media URL: {self.serv.media_endpoint}") async def cmd_media_path(self, args): if args.remove: