Drupal allows spaces in user names, so no need to convert them to underscores. Especially for users with hyphenated or apostrophised names. You don't want "Susan Porter-Smith" to become "Susan_Porter-Smith", or "Jim O'Hara" to become "Jim_O'Hara".
| Comment | File | Size | Author |
|---|---|---|---|
| #2 | use_trim_function-1263696-4922490.patch | 609 bytes | dan3h |
| #1 | spaces_ok_in_username-1263696.patch | 671 bytes | dan3h |
Comments
Comment #1
dan3h commentedHere's a patch for the very easy fix.
Comment #2
dan3h commentedHere is one more patch just to tighten up the code a tiny bit: use the trim() function-- it does what the two preg_replace functions were doing, and is more readable.
Comment #3
dwightaspinwall commentedHey nice catch Dan, and thanks for the patch. Let's get this reviewed and I'll get it in. Going on vacation for a couple weeks, so it'll need to wait.
Comment #4
dwightaspinwall commentedfixed in 6.x-1.3 and 7.x-1.0-beta6