master
Aevann1 2021-07-26 21:15:26 +02:00
parent b9a4710aa6
commit 6c8bec33e9
1 changed files with 11 additions and 12 deletions

View File

@ -115,7 +115,6 @@ def flagged_comments(v):
v=v,
standalone=True)
@app.route("/admin", methods=["GET"])
@admin_level_required(3)
def admin_home(v):
@ -124,6 +123,17 @@ def admin_home(v):
return render_template("admin/admin_home.html", v=v, x=x)
@app.route("/admin/disablesignups", methods=["POST"])
@admin_level_required(6)
@validate_formkey
def disablesignups(v):
with open('./disablesignups', 'wr') as f:
if f.read() == "yes": f.write("no")
else: f.write("yes")
return "", 204
@app.route("/admin/badge_grant", methods=["GET"])
@admin_level_required(4)
def badge_grant_get(v):
@ -539,17 +549,6 @@ def agendaposter(user_id, v):
else:
return redirect(user.url)
@app.route("/admin/disablesignups", methods=["POST"])
@admin_level_required(6)
@validate_formkey
def disablesignups(v):
with open('./disablesignups', 'w') as f:
if f.read() == "yes": f.write("no")
else: f.write("yes")
return "", 204
@app.route("/shadowban/<user_id>", methods=["POST"])
@admin_level_required(6)
@validate_formkey