remove leftover code

pull/219/head
Aevann 2023-12-03 19:46:03 +02:00
parent d291ddb0cb
commit 24fc61fedf
1 changed files with 0 additions and 19 deletions

View File

@ -47,9 +47,6 @@ def cron_fn(every_5m, every_1d, every_1mo):
_award_timers_task()
g.db.commit()
_unpin_expired()
g.db.commit()
_grant_one_year_badges()
g.db.commit()
@ -316,22 +313,6 @@ def _award_timers_task():
})
_process_timer(User.flairchanged, [96], "Your temporary flair-lock has expired. You can now change your flair!")
def _unpin_expired():
t = int(time.time())
pins = []
for cls in (Post, Comment):
pins += g.db.query(cls).options(load_only(cls.id)).filter(cls.stickied_utc < t)
for pin in pins:
pin.stickied = None
pin.stickied_utc = None
g.db.add(pin)
if pins:
cache.delete_memoized(frontlist)
def _give_marseybux_salary():
for u in g.db.query(User).filter(User.admin_level > 0).all():
marseybux_salary = u.admin_level * 10000