From 4ca765a41d845a104ab6888c702ba18beafa4a31 Mon Sep 17 00:00:00 2001 From: Bob Mottram Date: Thu, 3 Oct 2019 19:07:45 +0100 Subject: [PATCH] Set actor for reply --- inbox.py | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/inbox.py b/inbox.py index 480fa4b0d..5f059afd8 100644 --- a/inbox.py +++ b/inbox.py @@ -1334,6 +1334,12 @@ def inboxAfterCapabilities(session,keyId: str,handle: str,messageJson: {}, \ if validPostContent(messageJson['post'],maxMentions): if isDM(messageJson['post']): dmNotify(baseDir,handle) + domainFull=domain + if port: + if ':' not in domain: + if port!=80 and port!=443: + domainFull=domainFull+':'+str(port) + actor=httpPrefix+'://'+domainFull+'/users/'+handle.split('@')[0] if isReply(messageJson['post'],actor): replyNotify(baseDir,handle) obtainAvatarForReplyPost(session,baseDir,httpPrefix,domain,personCache,messageJson['post'],debug) @@ -1346,6 +1352,12 @@ def inboxAfterCapabilities(session,keyId: str,handle: str,messageJson: {}, \ if validPostContent(messageJson,maxMentions): if isDM(messageJson): dmNotify(baseDir,handle) + domainFull=domain + if port: + if ':' not in domain: + if port!=80 and port!=443: + domainFull=domainFull+':'+str(port) + actor=httpPrefix+'://'+domainFull+'/users/'+handle.split('@')[0] if isReply(messageJson,actor): replyNotify(baseDir,handle) obtainAvatarForReplyPost(session,baseDir,httpPrefix,domain,personCache,messageJson,debug)