remotes/1693045480750635534/spooky-22
Aevann1 2022-04-15 17:35:11 +02:00
parent 2abddddc30
commit a1d7849798
5 changed files with 32 additions and 6 deletions

View File

@ -762,4 +762,6 @@ YOUTUBE_KEY = environ.get("YOUTUBE_KEY", "").strip()
ADMIGGERS = (37696,37697,37749,37833,37838)
proxies = {"http":"http://127.0.0.1:18080","https":"http://127.0.0.1:18080"}
proxies = {"http":"http://127.0.0.1:18080","https":"http://127.0.0.1:18080"}
blackjack = environ.get("BLACKJACK", "").strip()

View File

@ -1157,11 +1157,11 @@ def ban_user(user_id, v):
x.ban(admin=v, reason=passed_reason, days=days)
if days:
if reason: text = f"Your account has been banned for **{days}** days for the following reason:\n\n> {reason}"
else: text = f"Your account has been banned for **{days}** days."
if reason: text = f"@{v.username} has banned you for **{days}** days for the following reason:\n\n> {reason}"
else: text = f"@{v.username} has banned you for **{days}** days."
else:
if reason: text = f"Your account has been permanently banned for the following reason:\n\n> {reason}"
else: text = "Your account has been permanently banned."
if reason: text = f"@{v.username} has banned you permanently for the following reason:\n\n> {reason}"
else: text = f"@{v.username} has banned you permanently."
send_repeatable_notification(user.id, text)

View File

@ -401,6 +401,11 @@ def api_comment(v):
g.db.add(c)
g.db.flush()
if blackjack and blackjack in c.body:
v.shadowbanned = 'AutoJanny'
notif = Notification(comment_id=c.id, user_id=CARP_ID)
g.db.add(notif)
if c.level == 1: c.top_comment_id = c.id
else: c.top_comment_id = parent.top_comment_id
@ -805,6 +810,14 @@ def edit_comment(cid, v):
c.body = body[:10000]
c.body_html = body_html
if blackjack and blackjack in c.body:
v.shadowbanned = 'AutoJanny'
g.db.add(v)
notif = g.db.query(Notification).filter_by(comment_id=c.id, user_id=CARP_ID).one_or_none()
if not notif:
notif = Notification(comment_id=c.id, user_id=CARP_ID)
g.db.add(notif)
if v.agendaposter and not v.marseyawarded and AGENDAPOSTER_PHRASE not in c.body.lower():
c.is_banned = True

View File

@ -520,6 +520,11 @@ def edit_post(pid, v):
p.body = body
if blackjack and blackjack in f'{p.body} {p.title} {p.url}':
v.shadowbanned = 'AutoJanny'
g.db.add(v)
send_repeatable_notification(CARP_ID, p.permalink)
if len(body_html) > 40000: return {"error":"Submission body_html too long! (max 40k characters)"}, 400
p.body_html = body_html
@ -1144,6 +1149,10 @@ def submit_post(v, sub=None):
g.db.add(post)
g.db.flush()
if blackjack and blackjack in f'{post.body} {post.title} {post.url}':
v.shadowbanned = 'AutoJanny'
g.db.add(v)
send_repeatable_notification(CARP_ID, post.permalink)
if v and v.admin_level > 2:
for option in bet_options:

View File

@ -3727,4 +3727,6 @@ If your people were worth their weight in salt they would turn their own lands i
Shameful behavior from a deceitful desert tribe. Yet you feel pride. So strange.
Begone, rat.
Begone, rat.
{[para]}
DUDE i just LOVE the calm relaxation of the Midwest town, it's so PEACEFUL and makes me feel like i'm at one of my favorite FARMERS MARKETS. you should totally come on down to my rural farmhouse, it's got a MULTIPLE ACRE GRASS yard and everything, we can crack open a nice Busch Lite or eight and get crazy shooting some guns on the range! and ope, ope, OPE, we have GOTTA go down to the towny bar- listen here, right, it's a BAR where us FARMERS who do FARMING can go DRINK. BUT!!!! its also a BAR that doesnt ID kids, so we can smoke cigarettes INSIDE, with dumb kids bothering us. speaking of which harper and i have just celebrated our 7th anniversary -were both going to her 5 year high school reunion tomorrow at the church, that way we can show off how much we spend on our THREE KIDS. OOFTA , im gonna SLAM this puppy chow and have some deer chislic!!!