From c915142089bd5c634820c9ddfebfda1f805202c9 Mon Sep 17 00:00:00 2001 From: Aevann1 Date: Mon, 7 Nov 2022 08:32:30 +0200 Subject: [PATCH] make 1 more button instant --- files/routes/subs.py | 2 +- files/templates/sub/mods.html | 13 ++++++++++++- 2 files changed, 13 insertions(+), 2 deletions(-) diff --git a/files/routes/subs.py b/files/routes/subs.py index b81de5c33..84413d5db 100644 --- a/files/routes/subs.py +++ b/files/routes/subs.py @@ -304,7 +304,7 @@ def remove_mod(v, sub): ) g.db.add(ma) - return redirect(f'/h/{sub}/mods') + return {"message": f"@{user.username} has been removed as a mod!"} @app.get("/create_hole") @is_not_permabanned diff --git a/files/templates/sub/mods.html b/files/templates/sub/mods.html index 054d050ca..d14f36ac5 100644 --- a/files/templates/sub/mods.html +++ b/files/templates/sub/mods.html @@ -1,5 +1,16 @@ {% extends "default.html" %} {% block content %} + + +
/h/{{sub}} Mods
@@ -17,7 +28,7 @@
{% if v.id == user.id or v.mod_date(sub.name) and v.mod_date(sub.name) < mod.created_utc %} -
+