forked from rDrama/rDrama
increase pronouns character limit from 11 characters to 15 characters
parent
f1e9f3e466
commit
57ac7f4f73
|
@ -127,7 +127,7 @@ search_token_regex = re.compile('"([^"]*)"|(\S+)', flags=re.A)
|
|||
|
||||
git_regex = re.compile("ref: (refs/.+)", flags=re.A)
|
||||
|
||||
pronouns_regex = re.compile("([a-z]{1,5})/[a-z]{1,5}(/[a-z]{1,5})?", flags=re.A|re.I)
|
||||
pronouns_regex = re.compile("([a-z]{1,7})/[a-z]{1,7}(/[a-z]{1,7})?", flags=re.A|re.I)
|
||||
|
||||
html_title_regex = re.compile("<title>(.{1,200})</title>", flags=re.I)
|
||||
|
||||
|
|
|
@ -918,8 +918,8 @@ def settings_title_change(v):
|
|||
def settings_pronouns_change(v):
|
||||
pronouns = sanitize_settings_text(request.values.get("pronouns"))
|
||||
|
||||
if len(pronouns) > 11:
|
||||
return redirect("/settings/personal?error=Your pronouns exceed the character limit (11 characters)")
|
||||
if len(pronouns) > 15:
|
||||
return redirect("/settings/personal?error=Your pronouns exceed the character limit (15 characters)")
|
||||
|
||||
if pronouns == v.pronouns:
|
||||
return redirect("/settings/personal?error=You didn't change anything!")
|
||||
|
|
|
@ -172,7 +172,7 @@
|
|||
</div>
|
||||
</div>
|
||||
{{common.color_section('namecolor', '/settings/namecolor', 'namecolor', 'Name Color', v.name_color)}}
|
||||
{{common.line_text_section('pronouns', '/settings/pronouns_change', 'pronouns', 'Pronouns', v.pronouns, 'Limit of 11 characters', 'Enter pronouns here', 'Change Pronouns', false, 3, 11, '([a-zA-Z]{1,5})/[a-zA-Z]{1,5}(/[a-zA-Z]{1,5})?', FEATURES['PRONOUNS'], false)}}
|
||||
{{common.line_text_section('pronouns', '/settings/pronouns_change', 'pronouns', 'Pronouns', v.pronouns, 'Limit of 15 characters', 'Enter pronouns here', 'Change Pronouns', false, 3, 15, '([a-zA-Z]{1,7})/[a-zA-Z]{1,7}(/[a-zA-Z]{1,7})?', FEATURES['PRONOUNS'], false)}}
|
||||
{# common.line_text_section(id, form_action, form_name, section_title, contents, below_text, placeholder_text, button_text, show_marseys, minlength, maxlength, pattern, show_if, disabled) #}
|
||||
{{common.line_text_section('flair', '/settings/title_change', 'title', 'Flair', v.customtitleplain, 'Limit of 100 characters', 'Enter a flair here', 'Change Flair', true, 0, 100, '.*', true, v.flairchanged)}}
|
||||
{{common.color_section('flaircolor', '/settings/titlecolor', 'titlecolor', 'Flair Color', v.titlecolor)}}
|
||||
|
|
Loading…
Reference in New Issue