Add case insensitive check to username validation
This commit is contained in:
parent
f8781ba5f3
commit
7321ee6f61
1 changed files with 1 additions and 1 deletions
|
|
@ -608,7 +608,7 @@ proc executeRegister(c: TForumData, name, pass, antibot, userIp,
|
|||
raise newForumError("Invalid username", @["username"])
|
||||
if getValue(
|
||||
db,
|
||||
sql"select name from person where name = ? and isDeleted = 0",
|
||||
sql"select name from person where name = ? collate nocase and isDeleted = 0",
|
||||
name
|
||||
).len > 0:
|
||||
raise newForumError("Username already exists", @["username"])
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue