Skip to content

Commit 28ccaea

Browse files
author
Santtu Pajukanta
committed
fix unicode strings with new mysqldb
1 parent 9933e29 commit 28ccaea

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

phpbb/auth/auth_db.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,9 @@ def login_db(username=None, password=None):
3838
if type(password) is unicode:
3939
password = password.encode("UTF-8")
4040

41-
user_row = get_user_row(utf8_clean_string(username))
41+
username_clean = utf8_clean_string(username).decode("UTF-8")
42+
43+
user_row = get_user_row(username_clean)
4244
if not user_row:
4345
return "LOGIN_ERROR_USERNAME", None
4446

0 commit comments

Comments
 (0)