mirror of https://gitlab.com/bashrc2/epicyon
Remove question from post cache
parent
e2a9814ef9
commit
ffe23ce23d
11
daemon.py
11
daemon.py
|
@ -221,6 +221,17 @@ class PubServer(BaseHTTPRequestHandler):
|
|||
if votesFile:
|
||||
votesFile.write(messageId+'\n')
|
||||
votesFile.close()
|
||||
|
||||
# ensure that the cached post is removed if it exists, so
|
||||
# that it then will be recreated
|
||||
cachedPostFilename= \
|
||||
getCachedPostFilename(self.server.baseDir, \
|
||||
nickname, \
|
||||
self.server.domain,messageJson)
|
||||
if os.path.isfile(cachedPostFilename):
|
||||
os.remove(cachedPostFilename)
|
||||
# remove from memory cache
|
||||
removePostFromCache(messageJson,self.server.recentPostsCache)
|
||||
else:
|
||||
print('ERROR: unable to post vote to outbox')
|
||||
else:
|
||||
|
|
Loading…
Reference in New Issue