forked from rDrama/rDrama
1
0
Fork 0

move execute_snappy to the bottom and see what happens

master
Aevann 2023-07-25 20:50:07 +03:00
parent 8c682f0686
commit a104337204
1 changed files with 3 additions and 3 deletions

View File

@ -715,9 +715,6 @@ def submit_post(v:User, sub=None):
autojanny.comment_count += 1
g.db.add(autojanny)
if not p.private and not (p.sub and g.db.query(Exile.user_id).filter_by(user_id=SNAPPY_ID, sub=p.sub).one_or_none()):
execute_snappy(p, v)
v.post_count = g.db.query(Post).filter_by(author_id=v.id, deleted_utc=0).count()
g.db.add(v)
@ -740,6 +737,9 @@ def submit_post(v:User, sub=None):
for key in redis_instance.scan_iter(key_pattern):
redis_instance.delete(key)
if not p.private:
execute_snappy(p, v)
if v.client: return p.json
else:
p.voted = 1