feat: pass in all query params to category search filter

isekai-main
Barış Soner Uşaklı 3 years ago
parent c4156bdd7b
commit 599bffd8e0

@ -50,12 +50,10 @@ module.exports = function (SocketCategories) {
}; };
async function findMatchedCids(uid, data) { async function findMatchedCids(uid, data) {
const result = await categories.search({ const params = { ...data, uid, paginate: false };
uid: uid, params.query = data.search;
query: data.search, params.qs = data.query;
paginate: false, const result = await categories.search(params);
});
let matchedCids = result.categories.map(c => c.cid); let matchedCids = result.categories.map(c => c.cid);
// no need to filter if all 3 states are used // no need to filter if all 3 states are used

Loading…
Cancel
Save