From 6162d02ca3c95228add4ce12390b9b3ddc27cf55 Mon Sep 17 00:00:00 2001 From: Aevann Date: Sat, 4 Mar 2023 23:45:12 +0200 Subject: [PATCH] forbid slots in ping group names --- files/routes/groups.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/files/routes/groups.py b/files/routes/groups.py index 8c8d8e471..1b2aae94c 100644 --- a/files/routes/groups.py +++ b/files/routes/groups.py @@ -25,6 +25,9 @@ def create_group(v): if not name: abort(400) name = name.strip().lower() + if name.startswith('slots'): + return redirect(f"/ping_groups?error=You can't make a group with that name!") + if not valid_sub_regex.fullmatch(name): return redirect(f"/ping_groups?error=Name does not match the required format!")