Skip to content
Snippets Groups Projects
Commit 3eea0436 authored by Jared Hancock's avatar Jared Hancock
Browse files

i18n: Allow Unicode characters in the username

parent 12da45f9
No related branches found
No related tags found
No related merge requests found
......@@ -173,7 +173,7 @@ class Validator {
function is_username($username, &$error='') {
if (strlen($username)<2)
$error = 'At least two (2) characters';
elseif (!preg_match('/^[\w._-]+$/', $username))
elseif (!preg_match('/^[\p{L}._-]+$/u', $username))
$error = 'Username contains invalid characters';
return $error == '';
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment