Skip to content

Commit

Permalink
fix developer index
Browse files Browse the repository at this point in the history
  • Loading branch information
Fleeym committed Jun 7, 2024
1 parent 31a1ad2 commit d9f81ab
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions src/types/models/developer.rs
Original file line number Diff line number Diff line change
Expand Up @@ -63,16 +63,16 @@ impl Developer {
);

if name_query.is_some() {
let sql = "WHERE username LIKE ";
let sql = "WHERE username = ";
builder.push(sql);
counter.push(sql);
builder.push_bind(name_query.clone().unwrap());
counter.push(name_query.clone().unwrap());
let sql = " OR WHERE display_name LIKE ";
builder.push_bind(query.clone().unwrap());
counter.push_bind(query.clone().unwrap());
let sql = " OR display_name ILIKE ";
builder.push(sql);
counter.push(sql);
builder.push(name_query.clone().unwrap());
counter.push(name_query.clone().unwrap());
builder.push_bind(name_query.clone().unwrap());
counter.push_bind(name_query.unwrap());
}

builder.push(" GROUP BY id");
Expand Down

0 comments on commit d9f81ab

Please sign in to comment.