forked from rDrama/rDrama
1
0
Fork 0
master
fireworks88 2021-07-26 16:45:02 +02:00
parent 5a81ed695c
commit 3c697f01f5
1 changed files with 10 additions and 6 deletions

View File

@ -6,7 +6,7 @@ from sqlalchemy.orm import lazyload
import threading import threading
import subprocess import subprocess
import imagehash import imagehash
from os import remove from os import remove, environ
from PIL import Image as IMAGE from PIL import Image as IMAGE
from drama.helpers.wrappers import * from drama.helpers.wrappers import *
@ -543,11 +543,15 @@ def agendaposter(user_id, v):
else: else:
return redirect(user.url) return redirect(user.url)
# @app.route("/disablesignups", methods=["POST"]) @app.route("/disablesignups", methods=["POST"])
# @admin_level_required(6) @admin_level_required(6)
# @validate_formkey @validate_formkey
# def disablesignups(v): def disablesignups(v):
# return "", 204
environ["DISABLESIGNUPS"] = "0" if app.config.get("DISABLESIGNUPS") else "1"
app.config["DISABLESIGNUPS"] = not app.config.get("DISABLESIGNUPS")
return "", 204
@app.route("/shadowban/<user_id>", methods=["POST"]) @app.route("/shadowban/<user_id>", methods=["POST"])