]> git.mxchange.org Git - fba.git/commitdiff
Continued:
authorRoland Häder <roland@mxchange.org>
Wed, 4 Oct 2023 08:18:54 +0000 (10:18 +0200)
committerRoland Häder <roland@mxchange.org>
Wed, 4 Oct 2023 08:18:54 +0000 (10:18 +0200)
- some people made a website which redirected to other redirect-only domains,
  e.g. start with 'social.golangengine.de' and you see what I mean
- if fetch_instances() is used here, it will cause a permanent redirect and
  later a stackoverflow

fba/http/federation.py

index 21566900cdf62748aed11cea098e8a263af7198e..3d6f57c662e1c8a5569639bedcc07a91812c54fe 100644 (file)
@@ -325,7 +325,7 @@ def fetch_generator_from_path(domain: str, path: str = "/") -> str:
             return None
         elif not instances.is_registered(domain2):
             logger.info("components.netloc='%s' is not registered, adding ...", components.netloc)
-            fetch_instances(domain2, domain, None, "redirect_target")
+            instances.add(domain2, domain, "redirect_target")
 
         message = f"Redirect from domain='{domain}' to response.url='{response.url}'"
         instances.set_last_error(domain, message)