forked from rDrama/rDrama
1
0
Fork 0

dont clean frontpage cache if its a comment that got pin-awarded

master
Aevann 2023-12-03 19:46:43 +02:00
parent 24fc61fedf
commit 393f8b4a7c
1 changed files with 3 additions and 1 deletions

View File

@ -318,6 +318,8 @@ def award_thing(v, thing_type, id):
obj.stickied_utc = int(time.time()) + add
obj.stickied = f'{v.username}{PIN_AWARD_TEXT}'
if isinstance(obj. Post):
cache.delete_memoized(frontlist)
elif kind == "unpin":
if not obj.stickied_utc: abort(400)