mirror of
https://github.com/Suwayomi/Suwayomi-Server.git
synced 2026-07-04 11:24:35 -05:00
empty searchTerm support (#259)
* linter run * convert search params to queryParams
This commit is contained in:
@@ -80,8 +80,8 @@ object SourceController {
|
||||
/** single source search */
|
||||
fun searchSingle(ctx: Context) {
|
||||
val sourceId = ctx.pathParam("sourceId").toLong()
|
||||
val searchTerm = ctx.pathParam("searchTerm")
|
||||
val pageNum = ctx.pathParam("pageNum").toInt()
|
||||
val searchTerm = ctx.queryParam("searchTerm") ?: ""
|
||||
val pageNum = ctx.queryParam("pageNum")?.toInt() ?: 1
|
||||
ctx.future(future { Search.sourceSearch(sourceId, searchTerm, pageNum) })
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user