mirror of
https://github.com/advplyr/audiobookshelf.git
synced 2025-08-03 17:54:54 +02:00
Fix search query
This commit is contained in:
parent
6c1b4e3a36
commit
6f96b069b5
2 changed files with 4 additions and 2 deletions
|
@ -39,9 +39,11 @@ module.exports = {
|
|||
* Search authors
|
||||
* @param {string} libraryId
|
||||
* @param {string} query
|
||||
* @param {number} limit
|
||||
* @param {number} offset
|
||||
* @returns {object[]} oldAuthor with numBooks
|
||||
*/
|
||||
async search(libraryId, query) {
|
||||
async search(libraryId, query, limit, offset) {
|
||||
const authors = await Database.authorModel.findAll({
|
||||
where: {
|
||||
name: {
|
||||
|
|
|
@ -1099,7 +1099,7 @@ module.exports = {
|
|||
}
|
||||
|
||||
// Search authors
|
||||
const authorMatches = await authorFilters.search(oldLibrary.id, query)
|
||||
const authorMatches = await authorFilters.search(oldLibrary.id, query, limit, offset)
|
||||
|
||||
return {
|
||||
book: itemMatches,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue