mirror of
https://github.com/LemmyNet/lemmy.git
synced 2024-10-01 01:36:12 -04:00
Bugfix: Adds case-insensitive SELECT queries to User_::find_by_username() (#1108)
This commit is contained in:
parent
4819bd5608
commit
0f8372c0fb
@ -142,7 +142,7 @@ impl User_ {
|
||||
}
|
||||
|
||||
pub fn find_by_username(conn: &PgConnection, username: &str) -> Result<User_, Error> {
|
||||
user_.filter(name.eq(username)).first::<User_>(conn)
|
||||
user_.filter(name.ilike(username)).first::<User_>(conn)
|
||||
}
|
||||
|
||||
pub fn find_by_email(conn: &PgConnection, from_email: &str) -> Result<User_, Error> {
|
||||
|
Loading…
Reference in New Issue
Block a user