Merge branch 'frost' of https://github.com/Aevann1/rDrama into frost
After Width: | Height: | Size: 13 KiB |
After Width: | Height: | Size: 8.5 KiB |
After Width: | Height: | Size: 19 KiB |
After Width: | Height: | Size: 17 KiB |
After Width: | Height: | Size: 7.8 KiB |
After Width: | Height: | Size: 11 KiB |
After Width: | Height: | Size: 1.4 MiB |
After Width: | Height: | Size: 32 KiB |
After Width: | Height: | Size: 24 KiB |
After Width: | Height: | Size: 10 KiB |
After Width: | Height: | Size: 63 KiB |
After Width: | Height: | Size: 3.2 KiB |
After Width: | Height: | Size: 1.7 KiB |
After Width: | Height: | Size: 3.7 KiB |
After Width: | Height: | Size: 6.1 KiB |
After Width: | Height: | Size: 814 B |
After Width: | Height: | Size: 5.7 KiB |
After Width: | Height: | Size: 318 KiB |
After Width: | Height: | Size: 259 KiB |
After Width: | Height: | Size: 18 KiB |
|
@ -840,11 +840,14 @@ class User(Base):
|
||||||
g.db.add(self)
|
g.db.add(self)
|
||||||
g.db.commit()
|
g.db.commit()
|
||||||
return
|
return
|
||||||
if u.is_suspended_permanently:
|
## Disabled pending better solution: permabans haven't propagated for
|
||||||
self.shadowbanned = u.banned_by.username
|
## most of Summer 2022. We've gotten somewhat used to this. Think we only
|
||||||
g.db.add(self)
|
## want them to propagate on account creation? Or at least needs discussion.
|
||||||
g.db.commit()
|
# if u.is_suspended_permanently:
|
||||||
return
|
# self.shadowbanned = u.banned_by.username
|
||||||
|
# g.db.add(self)
|
||||||
|
# g.db.commit()
|
||||||
|
# return
|
||||||
|
|
||||||
@property
|
@property
|
||||||
@lazy
|
@lazy
|
||||||
|
|
|
@ -32,8 +32,7 @@ def cron(every_5m, every_1h, every_1d, every_1mo):
|
||||||
spin_roulette_wheel()
|
spin_roulette_wheel()
|
||||||
offsitementions.offsite_mentions_task()
|
offsitementions.offsite_mentions_task()
|
||||||
if SITE_NAME == 'PCM':
|
if SITE_NAME == 'PCM':
|
||||||
cache.delete_memoized(route_static.live_cached)
|
route_static.live_cached(force=True)
|
||||||
route_static.live_cached()
|
|
||||||
|
|
||||||
if every_1h:
|
if every_1h:
|
||||||
awards.award_timers_bots_task()
|
awards.award_timers_bots_task()
|
||||||
|
|
|
@ -443,8 +443,10 @@ if SITE == 'pcmemes.net':
|
||||||
live_thumb_regex = re.compile('\{"thumbnail":\{"thumbnails":\[\{"url":"(.*?)"', flags=re.A)
|
live_thumb_regex = re.compile('\{"thumbnail":\{"thumbnails":\[\{"url":"(.*?)"', flags=re.A)
|
||||||
offline_regex = re.compile('","title":"(.*?)".*?"width":48,"height":48\},\{"url":"(.*?)"', flags=re.A)
|
offline_regex = re.compile('","title":"(.*?)".*?"width":48,"height":48\},\{"url":"(.*?)"', flags=re.A)
|
||||||
|
|
||||||
@cache.memoize(timeout=86400)
|
@cache.memoize(timeout=86400,
|
||||||
def live_cached():
|
forced_update=(lambda force=False: force),
|
||||||
|
args_to_ignore=["force"])
|
||||||
|
def live_cached(force=False):
|
||||||
live = []
|
live = []
|
||||||
offline = []
|
offline = []
|
||||||
db = db_session()
|
db = db_session()
|
||||||
|
|