This repository has been archived on 2024-06-08. You can view files and clone it, but cannot push or open issues or pull requests.
tachiyomi/app
curche 7e3ea9074c
Extend library search by adding -<source> option (#5387)
* extend library search to enable -<source> search

library search already allows for <source> search to select manga from a
particular source. Similarly, -<source> allows to search for manga that
aren't from the said source. TachiyomiSy has this feature but it heavily
depends on exh methods

A problem when you directly add a negation check is that although
it will work, the genre search kicks in adds back every manga since
-<source> returns true for all genres of a manga

Thus, the solution I decided on was do source search first, and then
move to genre check when it fails. A perhaps useful addition is that,
now you're able to search like this:
 <genre1>, -<source>, -<genre2>

* make if-else statements more readable

* refactor containsSourceOrGenre() using `when`

* add comment describing the function

* remove lazy

not really required anymore now that containsSourceOrGenre was rewritten
using `when`
2021-06-28 11:32:03 -04:00
..
src Extend library search by adding -<source> option (#5387) 2021-06-28 11:32:03 -04:00
.gitignore Move google-services.json 2020-04-29 17:56:05 -04:00
build.gradle.kts Sort per category (#5408) 2021-06-26 13:30:16 -04:00
proguard-android-optimize.txt Reinstate Proguard/R8 (#5134) 2021-05-22 14:47:40 -04:00
proguard-rules.pro Fix missing Injekt method crash (fixes #7355) 2021-05-31 19:34:54 -04:00
shortcuts.xml Remove more unused strings 2021-05-30 11:10:16 -04:00