forked from rDrama/rDrama
forbid slots in ping group names
parent
f10c8b0db8
commit
6162d02ca3
|
@ -25,6 +25,9 @@ def create_group(v):
|
||||||
if not name: abort(400)
|
if not name: abort(400)
|
||||||
name = name.strip().lower()
|
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):
|
if not valid_sub_regex.fullmatch(name):
|
||||||
return redirect(f"/ping_groups?error=Name does not match the required format!")
|
return redirect(f"/ping_groups?error=Name does not match the required format!")
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue