Skip to content

Commit d9f81ab

Browse files
committed
fix developer index
1 parent 31a1ad2 commit d9f81ab

File tree

1 file changed

+6
-6
lines changed

1 file changed

+6
-6
lines changed

src/types/models/developer.rs

+6-6
Original file line numberDiff line numberDiff line change
@@ -63,16 +63,16 @@ impl Developer {
6363
);
6464

6565
if name_query.is_some() {
66-
let sql = "WHERE username LIKE ";
66+
let sql = "WHERE username = ";
6767
builder.push(sql);
6868
counter.push(sql);
69-
builder.push_bind(name_query.clone().unwrap());
70-
counter.push(name_query.clone().unwrap());
71-
let sql = " OR WHERE display_name LIKE ";
69+
builder.push_bind(query.clone().unwrap());
70+
counter.push_bind(query.clone().unwrap());
71+
let sql = " OR display_name ILIKE ";
7272
builder.push(sql);
7373
counter.push(sql);
74-
builder.push(name_query.clone().unwrap());
75-
counter.push(name_query.clone().unwrap());
74+
builder.push_bind(name_query.clone().unwrap());
75+
counter.push_bind(name_query.unwrap());
7676
}
7777

7878
builder.push(" GROUP BY id");

0 commit comments

Comments
 (0)