NHentai - safe call (#3677)

This commit is contained in:
Mike 2020-07-03 01:59:29 -04:00 committed by GitHub
parent ddb0fbacff
commit cb5865ffb7
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 2 additions and 2 deletions

View File

@ -5,7 +5,7 @@ ext {
extName = 'NHentai' extName = 'NHentai'
pkgNameSuffix = 'all.nhentai' pkgNameSuffix = 'all.nhentai'
extClass = '.NHFactory' extClass = '.NHFactory'
extVersionCode = 25 extVersionCode = 26
libVersion = '1.2' libVersion = '1.2'
} }

View File

@ -167,7 +167,7 @@ open class NHentai(
.addQueryParameter("q", "$query +$nhLang $advQuery") .addQueryParameter("q", "$query +$nhLang $advQuery")
.addQueryParameter("page", page.toString()) .addQueryParameter("page", page.toString())
if (uploadedFilter!!.state.isBlank()) { if (uploadedFilter?.state?.isBlank() == true) {
filters.findInstance<SortFilter>()?.let { f -> filters.findInstance<SortFilter>()?.let { f ->
url.addQueryParameter("sort", f.toUriPart()) url.addQueryParameter("sort", f.toUriPart())
} }