diff --git a/api/funkwhale_api/federation/authentication.py b/api/funkwhale_api/federation/authentication.py index 171b66106..1ecee00e9 100644 --- a/api/funkwhale_api/federation/authentication.py +++ b/api/funkwhale_api/federation/authentication.py @@ -81,11 +81,12 @@ class SignatureAuthentication(authentication.BaseAuthentication): fetch_delay = 24 * 3600 now = timezone.now() last_fetch = actor.domain.nodeinfo_fetch_date - if not last_fetch or ( - last_fetch < (now - datetime.timedelta(seconds=fetch_delay)) - ): - tasks.update_domain_nodeinfo(domain_name=actor.domain.name) - actor.domain.refresh_from_db() + if not actor.domain.is_local: + if not last_fetch or ( + last_fetch < (now - datetime.timedelta(seconds=fetch_delay)) + ): + tasks.update_domain_nodeinfo(domain_name=actor.domain.name) + actor.domain.refresh_from_db() return actor def authenticate(self, request):