forked from indymedia/epicyon
Save to a named file
parent
672f466cf0
commit
e5e3987699
|
@ -197,10 +197,12 @@ def postMessageToOutbox(messageJson: {}, postToNickname: str,
|
||||||
|
|
||||||
# save all instance blogs to the news actor
|
# save all instance blogs to the news actor
|
||||||
if postToNickname != 'news' and outboxName == 'tlblogs':
|
if postToNickname != 'news' and outboxName == 'tlblogs':
|
||||||
|
if '/' in savedFilename:
|
||||||
|
savedPostId = savedFilename.split('/')[-1]
|
||||||
blogsDir = baseDir + '/accounts/news@' + domain + '/tlblogs'
|
blogsDir = baseDir + '/accounts/news@' + domain + '/tlblogs'
|
||||||
if not os.path.isdir(blogsDir):
|
if not os.path.isdir(blogsDir):
|
||||||
os.mkdir(blogsDir)
|
os.mkdir(blogsDir)
|
||||||
copyfile(savedFilename, blogsDir)
|
copyfile(savedFilename, blogsDir + '/' + savedPostId)
|
||||||
inboxUpdateIndex('tlblogs', baseDir,
|
inboxUpdateIndex('tlblogs', baseDir,
|
||||||
'news@' + domain,
|
'news@' + domain,
|
||||||
savedFilename, debug)
|
savedFilename, debug)
|
||||||
|
|
Loading…
Reference in New Issue