same as last commit

pull/200/head
Aevann 2023-09-11 21:12:10 +03:00
parent b7e3f7719e
commit 6fe7c655d2
1 changed files with 4 additions and 1 deletions

View File

@ -44,6 +44,10 @@ def get_mentions(cache, queries, reddit_notifs_users=False):
data = sorted(data, key=lambda x: int(x['created_utc']), reverse=True)
for thing in data:
if not thing['permalink']:
print(thing, flush=True)
continue
if thing['subreddit'] in {'IAmA', 'PokemonGoRaids', 'SubSimulatorGPT2', 'SubSimGPT2Interactive'}: continue
if 'bot' in thing['author'].lower(): continue
if 'AutoModerator' == thing['author']: continue
@ -60,7 +64,6 @@ def get_mentions(cache, queries, reddit_notifs_users=False):
if thing["selftext"]:
selftext = thing["selftext"].replace('>', '> ')[:5000]
text += f'<br><blockquote><p>{selftext}</p></blockquote>'
mentions.append({
'permalink': thing['permalink'],
'author': thing['author'],