mirror of
https://github.com/LemmyNet/lemmy.git
synced 2024-12-22 19:01:32 +00:00
converted like to ilike in filter
This commit is contained in:
parent
c4e83912e1
commit
0441a7dc84
1 changed files with 3 additions and 5 deletions
|
@ -214,8 +214,6 @@ fn queries<'a>() -> Queries<
|
|||
options.local_user.person_id(),
|
||||
);
|
||||
|
||||
query.filter
|
||||
|
||||
// hide posts from deleted communities
|
||||
query = query.filter(community::deleted.eq(false));
|
||||
|
||||
|
@ -360,9 +358,9 @@ fn queries<'a>() -> Queries<
|
|||
query = query.filter(instance_actions::blocked.is_null());
|
||||
query = query.filter(person_actions::blocked.is_null());
|
||||
query = query.filter(
|
||||
not(post::name.like(any(post_keyword_block::keyword)))
|
||||
.and(not(post::body.like(any(post_keyword_block::keyword))))
|
||||
.and(not(post::url.like(any(post_keyword_block::keyword)))));
|
||||
not(post::name.ilike(post_keyword_block::keyword))
|
||||
.and(not(post::body.ilike(post_keyword_block::keyword)))
|
||||
.and(not(post::url.ilike(post_keyword_block::keyword))));
|
||||
}
|
||||
|
||||
let (limit, offset) = limit_and_offset(options.page, options.limit)?;
|
||||
|
|
Loading…
Reference in a new issue