Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
mahara
mahara
Commits
24bc4d44
Commit
24bc4d44
authored
Apr 06, 2010
by
Richard Mansfield
Browse files
Merge commit 'mahara-security/master'
parents
0e8c9a17
8fded07f
Changes
1
Hide whitespace changes
Inline
Side-by-side
htdocs/lib/user.php
View file @
24bc4d44
...
...
@@ -1216,7 +1216,8 @@ function get_new_username($desired) {
$desired
=
strtolower
(
substr
(
$desired
,
0
,
$maxlen
));
$taken
=
get_column_sql
(
'
SELECT username FROM {usr}
WHERE username '
.
db_ilike
()
.
" '"
.
substr
(
$desired
,
0
,
$maxlen
-
6
)
.
"%'"
);
WHERE username '
.
db_ilike
()
.
" ?"
,
array
(
substr
(
$desired
,
0
,
$maxlen
-
6
)
.
'%'
));
if
(
!
$taken
)
{
return
$desired
;
}
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment