forked from indymedia/epicyon
Check the published date on downloaded announces
parent
ae7e0a8912
commit
b257f90df2
7
posts.py
7
posts.py
|
@ -30,6 +30,7 @@ from session import postJsonString
|
|||
from session import postImage
|
||||
from webfinger import webfingerHandle
|
||||
from httpsig import createSignedHeader
|
||||
from utils import validPostDate
|
||||
from utils import getFullDomain
|
||||
from utils import getFollowersList
|
||||
from utils import isEvil
|
||||
|
@ -3817,6 +3818,12 @@ def downloadAnnounce(session, baseDir: str, httpPrefix: str,
|
|||
if not announcedJson.get('content'):
|
||||
rejectAnnounce(announceFilename)
|
||||
return None
|
||||
if not announcedJson.get('published'):
|
||||
rejectAnnounce(announceFilename)
|
||||
return None
|
||||
if not validPostDate(announcedJson['published']):
|
||||
rejectAnnounce(announceFilename)
|
||||
return None
|
||||
if isFiltered(baseDir, nickname, domain, announcedJson['content']):
|
||||
rejectAnnounce(announceFilename)
|
||||
return None
|
||||
|
|
Loading…
Reference in New Issue