From f88efa40d497995a5f645d03f99345c804f808d7 Mon Sep 17 00:00:00 2001 From: Michael Manfre Date: Tue, 22 Nov 2022 23:53:02 -0500 Subject: Code dedupe Webfinger and fix SystemActor inbox URL --- users/models/system_actor.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'users/models') diff --git a/users/models/system_actor.py b/users/models/system_actor.py index 28ef1a8..c337d78 100644 --- a/users/models/system_actor.py +++ b/users/models/system_actor.py @@ -22,6 +22,9 @@ class SystemActor: self.profile_uri = f"https://{settings.MAIN_DOMAIN}/about/" self.username = "__system__" + def absolute_profile_uri(self): + return self.profile_uri + def generate_keys(self): self.private_key, self.public_key = RsaKeys.generate_keypair() Config.set_system("system_actor_private_key", self.private_key) @@ -39,7 +42,7 @@ class SystemActor: return { "id": self.actor_uri, "type": "Application", - "inbox": self.actor_uri + "/inbox/", + "inbox": self.actor_uri + "inbox/", "preferredUsername": self.username, "url": self.profile_uri, "as:manuallyApprovesFollowers": True, -- cgit v1.2.3