From 591fe9721fb3fd81404232dfb68ec6a819acba78 Mon Sep 17 00:00:00 2001 From: justcool393 Date: Mon, 3 Oct 2022 01:18:06 -0700 Subject: [PATCH] don't let shadowbanned users create holes --- files/routes/subs.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/files/routes/subs.py b/files/routes/subs.py index 516ee789f3..f9ccbb6b4c 100644 --- a/files/routes/subs.py +++ b/files/routes/subs.py @@ -362,8 +362,8 @@ def create_sub2(v): return render_template("sub/create_hole.html", v=v, cost=HOLE_COST, error="You don't have enough coins!"), 403 v.coins -= HOLE_COST - g.db.add(v) + if v.shadowbanned: return {"error": "Internal Server Error"}, 500 sub = Sub(name=name) g.db.add(sub)