Permalink
Browse files

removing extra validation for extended username characters.

  • Loading branch information...
1 parent 0ae9812 commit f40654471398a09b115f0eaf1c5263a21c74a840 @rwijaya rwijaya committed Jan 14, 2010
Showing with 4 additions and 6 deletions.
  1. +4 −6 user/editadvanced_form.php
View
@@ -145,12 +145,10 @@ function validation($usernew, $files) {
//check allowed characters
if ($usernew->username !== moodle_strtolower($usernew->username)) {
$err['username'] = get_string('usernamelowercase');
- } else {
- if (empty($CFG->extendedusernamechars)) {
- $string = clean_param($usernew->username, PARAM_USERNAME);
- if ($usernew->username !== $string) {
- $err['username'] = get_string('invalidusername');
- }
+ } else {
+ $string = clean_param($usernew->username, PARAM_USERNAME);
+ if ($usernew->username !== $string) {
+ $err['username'] = get_string('invalidusername');
}
}
}

0 comments on commit f406544

Please sign in to comment.