Rebuild the list of instances that use this relay every time / is requested
authorFinn Herzfeld <finn@social.seattle.wa.us>
Mon, 10 Dec 2018 22:14:43 +0000 (14:14 -0800)
committerFinn Herzfeld <finn@social.seattle.wa.us>
Mon, 10 Dec 2018 22:14:43 +0000 (14:14 -0800)
relay/default.py

index 638e0c7..b3a1836 100644 (file)
@@ -7,9 +7,9 @@ host = CONFIG['ap']['host']
 note = CONFIG['note']
 
 inboxes = DATABASE.get('relay-list', [])
-targets = '<br>'.join([urllib.parse.urlsplit(target).hostname for target in inboxes])
 
 async def default(request):
+    targets = '<br>'.join([urllib.parse.urlsplit(target).hostname for target in inboxes])
     return aiohttp.web.Response(
         status=200,
         content_type="text/html",