From d1702aa4165a25d8673429904a76ec4584a95611 Mon Sep 17 00:00:00 2001 From: Diego Mello Date: Thu, 15 Jul 2021 11:34:39 -0300 Subject: [PATCH] Regression: Settings pagination not working (#3277) --- app/lib/methods/getSettings.js | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/app/lib/methods/getSettings.js b/app/lib/methods/getSettings.js index c51ac406..be6ef1ee 100644 --- a/app/lib/methods/getSettings.js +++ b/app/lib/methods/getSettings.js @@ -138,9 +138,10 @@ export function subscribeSettings() { export default async function() { try { const db = database.active; - const settingsParams = JSON.stringify(Object.keys(settings).filter(key => !loginSettings.includes(key))); + const settingsParams = Object.keys(settings).filter(key => !loginSettings.includes(key)); // RC 0.60.0 - const result = await fetch(`${ this.sdk.client.host }/api/v1/settings.public?query={"_id":{"$in":${ settingsParams }}}`).then(response => response.json()); + const result = await fetch(`${ this.sdk.client.host }/api/v1/settings.public?query={"_id":{"$in":${ JSON.stringify(settingsParams) }}}&count=${ settingsParams.length }`) + .then(response => response.json()); if (!result.success) { return;