Remove references to r/Drama archives

This commit is contained in:
iro84657 2022-05-09 22:02:15 -04:00
parent 8c2ee6a57a
commit 2eb2d6a034

View file

@ -10,12 +10,6 @@ import matplotlib.pyplot as plt
from files.classes.mod_logs import ACTIONTYPES, ACTIONTYPES2 from files.classes.mod_logs import ACTIONTYPES, ACTIONTYPES2
from files.classes.badges import BadgeDef from files.classes.badges import BadgeDef
@app.get("/r/drama/comments/<id>/<title>")
@app.get("/r/Drama/comments/<id>/<title>")
def rdrama(id, title):
id = ''.join(f'{x}/' for x in id)
return redirect(f'/archives/drama/comments/{id}{title}.html')
@app.get('/logged_out/') @app.get('/logged_out/')
@app.get('/logged_out/<path:old>') @app.get('/logged_out/<path:old>')
def logged_out(old = ""): def logged_out(old = ""):
@ -340,16 +334,6 @@ def submit_contact(v):
g.db.commit() g.db.commit()
return render_template("contact.html", v=v, msg="Your message has been sent.") return render_template("contact.html", v=v, msg="Your message has been sent.")
@app.get('/archives')
def archivesindex():
return redirect("/archives/index.html")
@app.get('/archives/<path:path>')
def archives(path):
resp = make_response(send_from_directory('/archives', path))
if request.path.endswith('.css'): resp.headers.add("Content-Type", "text/css")
return resp
@app.get('/e/<emoji>') @app.get('/e/<emoji>')
@limiter.exempt @limiter.exempt
def emoji(emoji): def emoji(emoji):