mirror of https://gitlab.com/bashrc2/epicyon
Use full post id
parent
36077696a8
commit
e97dc8c8ce
19
daemon.py
19
daemon.py
|
@ -6740,13 +6740,14 @@ class PubServer(BaseHTTPRequestHandler):
|
|||
# save the announce straight to the outbox
|
||||
# This is because the subsequent send is within a separate thread
|
||||
# but the html still needs to be generated before this call ends
|
||||
announceId = removeIdEnding(announceJson['id'])
|
||||
# announceId = removeIdEnding(announceJson['id'])
|
||||
announceId = announceJson['id']
|
||||
announceFilename = \
|
||||
savePostToBox(baseDir, httpPrefix, announceId,
|
||||
self.postToNickname, domainFull,
|
||||
announceJson, 'outbox')
|
||||
# also copy the post id to the inbox index
|
||||
indexes = ['outbox', 'inbox']
|
||||
indexes = ['inbox']
|
||||
for boxNameIndex in indexes:
|
||||
inboxUpdateIndex(boxNameIndex, baseDir,
|
||||
self.postToNickname + '@' + domain,
|
||||
|
@ -6760,14 +6761,12 @@ class PubServer(BaseHTTPRequestHandler):
|
|||
self._postToOutboxThread(announceJson)
|
||||
|
||||
# generate the html for the announce
|
||||
if announceFilename:
|
||||
if announceJson and announceFilename:
|
||||
print('Generating html post for announce')
|
||||
announcePostJson = loadJson(announceFilename, 0, 1)
|
||||
if announcePostJson:
|
||||
cachedPostFilename = \
|
||||
getCachedPostFilename(baseDir, self.postToNickname,
|
||||
domain, announcePostJson)
|
||||
print('Announced post json: ' + str(announcePostJson))
|
||||
domain, announceJson)
|
||||
print('Announced post json: ' + str(announceJson))
|
||||
print('Announced post nickname: ' +
|
||||
self.postToNickname + ' ' + domain)
|
||||
print('Announced post cache: ' + str(cachedPostFilename))
|
||||
|
@ -6784,7 +6783,7 @@ class PubServer(BaseHTTPRequestHandler):
|
|||
self.server.cachedWebfingers,
|
||||
self.server.personCache,
|
||||
self.postToNickname, domain,
|
||||
self.server.port, announcePostJson,
|
||||
self.server.port, announceJson,
|
||||
None, True,
|
||||
self.server.allowDeletion,
|
||||
httpPrefix, self.server.projectVersion,
|
||||
|
@ -6796,12 +6795,10 @@ class PubServer(BaseHTTPRequestHandler):
|
|||
self.server.themeName,
|
||||
self.server.systemLanguage,
|
||||
self.server.maxLikeCount,
|
||||
not isDM(announcePostJson),
|
||||
not isDM(announceJson),
|
||||
showIndividualPostIcons,
|
||||
manuallyApproveFollowers,
|
||||
False, True, False)
|
||||
else:
|
||||
print('WARN: Announced post not found: ' + announceFilename)
|
||||
|
||||
self.server.GETbusy = False
|
||||
actorAbsolute = self._getInstalceUrl(callingDomain) + actor
|
||||
|
|
Loading…
Reference in New Issue