forked from indymedia/epicyon
Check that index exists
parent
4213a1981a
commit
7ffc14e0fb
6
utils.py
6
utils.py
|
@ -465,8 +465,10 @@ def removePostFromCache(postJsonObject: {},recentPostsCache: {}):
|
|||
if postId not in recentPostsCache['index']:
|
||||
return
|
||||
|
||||
del recentPostsCache['json'][postId]
|
||||
del recentPostsCache['html'][postId]
|
||||
if recentPostsCache['json'].get(postId):
|
||||
del recentPostsCache['json'][postId]
|
||||
if recentPostsCache['html'].get(postId):
|
||||
del recentPostsCache['html'][postId]
|
||||
recentPostsCache['index'].remove(postId)
|
||||
|
||||
def updateRecentPostsCache(recentPostsCache: {},maxRecentPosts: int, \
|
||||
|
|
Loading…
Reference in New Issue